aboutsummaryrefslogtreecommitdiff
path: root/uxd.1
diff options
context:
space:
mode:
authorB. Watson <urchlay@slackware.uk>2024-12-18 07:05:01 -0500
committerB. Watson <urchlay@slackware.uk>2024-12-18 07:05:01 -0500
commitd0b8532b703ef515b89eb8f34c0402262f3d3f7e (patch)
tree58ad6115dbf5ce685823aaf082558418be32c995 /uxd.1
parentc6ed5c95a56e55a2bb33c9dca819ddf377f05575 (diff)
downloaduxd-d0b8532b703ef515b89eb8f34c0402262f3d3f7e.tar.gz
add -j/-p/-w options.
Diffstat (limited to 'uxd.1')
-rw-r--r--uxd.142
1 files changed, 39 insertions, 3 deletions
diff --git a/uxd.1 b/uxd.1
index 6258f9c..8ada567 100644
--- a/uxd.1
+++ b/uxd.1
@@ -121,6 +121,17 @@ bad sequences.
.
.INDENT 0.0
.TP
+.B \-j
+Java mode (aka MUTF\-8). Identical to UTF\-8 except it allows the
+overlong \fB0xc0 0x80\fP encoding for codepoint U+0000 (aka NUL),
+which normally would be considered an error.
+This may be useful for looking at serialized data created by Java
+programs.
+.UNINDENT
+.\" java (MUTF-8) mode: allow 0xc0 0x80 for U+0000.
+.
+.INDENT 0.0
+.TP
.BI \-l \ length
Stop dumping after \fIlength\fP bytes (not characters). If the limit is
reached in the middle of a multibyte character, the entire character
@@ -157,6 +168,11 @@ if you can think of a reason to want it to be.
.
.INDENT 0.0
.TP
+.B \-p
+Permissive mode. Turns off error highlighting for overlongs, codepoints
+above \fBU+10FFFF\fP, and surrogates. Only malformed sequences will be
+highlighed in red.
+.TP
.B \-r
Highlight multi\-byte sequences in reverse video, in the hex
output. Ignored if \fB\-m\fP given.
@@ -218,6 +234,13 @@ Print version number and exit.
.UNINDENT
.\" print version of uxd.
.
+.INDENT 0.0
+.TP
+.B \-w
+WTF\-8 mode. Surrogates \fBU+D800\fP to \fBU+D8FF\fP will not be considered errors.
+.UNINDENT
+.\" WTF-8 mode (allow surrogates).
+.
.SH OUTPUT FORMAT
.sp
The output is designed to fit in an 80\-column terminal.
@@ -389,10 +412,23 @@ Zero for success, non\-zero for failure.
Failure status will only be returned if \fBuxd\fP failed to open the
input file. Invalid input (non\-UTF\-8) doesn\(aqt count as an error;
it\(aqll just have lots of red in the output.
-.SH BUGS
+.SH LIMITATIONS
+.sp
+There are not bugs, because they\(aqre part of the design.
+.sp
+Only UTF\-8 and a couple of variants (WTF\-8, MUTF\-8) are supported.
+There is no support for UTF\-16, UTF\-32, UTF\-EBCDIC, or any other
+non\-UTF\-8 encoding.
.sp
-There should be options and/or a config file to change the colors,
-rather than baking them into the binary.
+There\(aqs no support for any number base except hex.
+.sp
+The input is read one byte at a time, so a search or regex match
+option would be difficult or impossible to implement.
+.sp
+Seeking backwards from the end of the file is impossible when reading
+from standard input. The only way to fake this would be to read the
+whole file into memory at startup, which \fBuxd\fP doesn\(aqt do.
+.SH BUGS
.sp
Combining characters are not handled well. Or at all, really: the 2
characters being combined will have an ANSI color code in between.