Skip to content

tr: Should handle high input bytes in command-line #6343

@BenWiederhake

Description

@BenWiederhake
$ 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)

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions