coreutils
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[PATCH] doc: od --strings: clarify operation


From: Pádraig Brady
Subject: [PATCH] doc: od --strings: clarify operation
Date: Thu, 8 Jun 2023 11:09:53 +0100

* doc/coreutils.texi (od invocation): Remove mention of ASCII,
as all printable characters in unibyte locales are output.
* src/od.c (usage): Clarify that only NUL terminated strings
are displayed, and that it's printable chars, not only graphic chars
that are output. I.e., spaces are output also if part of the string.
Reported at https://bugs.ddebian.org/1037217
---
 doc/coreutils.texi | 2 +-
 src/od.c           | 5 ++---
 2 files changed, 3 insertions(+), 4 deletions(-)

diff --git a/doc/coreutils.texi b/doc/coreutils.texi
index 6a693e283..e9d7b8eb4 100644
--- a/doc/coreutils.texi
+++ b/doc/coreutils.texi
@@ -2058,7 +2058,7 @@ Output at most @var{bytes} bytes of the input.  Prefixes 
and suffixes on
 @opindex --strings
 @cindex string constants, outputting
 Instead of the normal output, output only @dfn{string constants}: at
-least @var{bytes} consecutive ASCII graphic characters,
+least @var{bytes} consecutive printable characters,
 followed by a zero byte (ASCII NUL).
 Prefixes and suffixes on @var{bytes} are interpreted as for the
 @option{-j} option.
diff --git a/src/od.c b/src/od.c
index 10a28e21f..f68407008 100644
--- a/src/od.c
+++ b/src/od.c
@@ -356,9 +356,8 @@ suffixes may be . for octal and b for multiply by 512.\n\
 "), stdout);
       fputs (_("\
   -N, --read-bytes=BYTES      limit dump to BYTES input bytes\n\
-  -S BYTES, --strings[=BYTES]  output strings of at least BYTES graphic chars;\
-\n\
-                                3 is implied when BYTES is not specified\n\
+  -S BYTES, --strings[=BYTES]  show only NUL terminated strings\n\
+                                of at least BYTES (3) printable characters\n\
   -t, --format=TYPE           select output format or formats\n\
   -v, --output-duplicates     do not use * to mark line suppression\n\
   -w[BYTES], --width[=BYTES]  output BYTES bytes per output line;\n\
-- 
2.40.1




reply via email to

[Prev in Thread] Current Thread [Next in Thread]