]> git.ipfire.org Git - thirdparty/coreutils.git/commitdiff
doc: dd: document the behavior of conv flags on multibyte characters master
authorCollin Funk <collin.funk1@gmail.com>
Sat, 13 Dec 2025 07:11:09 +0000 (23:11 -0800)
committerCollin Funk <collin.funk1@gmail.com>
Sun, 14 Dec 2025 02:55:00 +0000 (18:55 -0800)
* doc/coreutils.texi (dd invocation): Document the behavior of 'dd' on
multibyte characters and some unspecified behavior that will be
documented in a future POSIX release [1].

[1] https://austingroupbugs.net/view.php?id=1959

doc/coreutils.texi

index d37cf2471426294a05ff2afc613d92f1477c0001..cab87454eacd3b774b99fe68352cc759e37ccfa6 100644 (file)
@@ -9280,6 +9280,17 @@ Change lowercase letters to uppercase.
 
 The @samp{lcase} and @samp{ucase} conversions are mutually exclusive.
 
 
 The @samp{lcase} and @samp{ucase} conversions are mutually exclusive.
 
+@c https://austingroupbugs.net/view.php?id=1959
+POSIX leaves the behavior of @samp{lcase} and @samp{ucase} unspecified
+on multibyte characters.  GNU @command{dd} supports only unibyte
+conversion, because multibyte characters may cross block boundaries and
+case conversion may change the length of characters.
+
+POSIX also leaves the behavior of @samp{lcase} and @samp{ucase}
+unspecified if used with @samp{ascii}, @samp{ebcdic}, or @samp{ibm}.
+GNU @command{dd} will perform the case conversion and then perform the
+character set conversion.
+
 @item sparse
 @opindex sparse
 Try to seek rather than write NUL output blocks.
 @item sparse
 @opindex sparse
 Try to seek rather than write NUL output blocks.