uutils / coreutils

Cross-platform Rust rewrite of the GNU coreutils

Home Page:https://uutils.github.io/

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

tr: Should handle high input bytes in command-line

BenWiederhake opened this issue · comments

$ echo -en '\001amp\0376\0377' | tr $'a\xfe\xffz' "01234" | hd
00000000  01 30 6d 70 31 32                                 |.0mp12|
00000006
$ echo -en '\001amp\0376\0377' | cargo run tr $'a\xfe\xffz' "01234" | hd
error: invalid UTF-8 was detected in one or more arguments

Usage: target/debug/coreutils tr [OPTION]... SET1 [SET2]

For more information, try '--help'.

(Original issue: #6133)