[Bug 223598] ls utf output

bugzilla-noreply at freebsd.org bugzilla-noreply at freebsd.org
Fri Nov 10 18:55:49 UTC 2017


https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=223598

Conrad Meyer <cem at freebsd.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |cem at freebsd.org

--- Comment #2 from Conrad Meyer <cem at freebsd.org> ---
If ls's output is going to a tty (ordinary shell session), it defaults to
f_nonprint=1, which replaces anything not printable in the current locale as ?.
 When you pipe its output to anything else (grep, cat, whatever), it defaults
to f_nonprint=0, passing the raw bytes through.  Your local terminal is in
UTF-8 mode and can decode the bytes.

This behavior can be overridden with 'ls -w'.  Or you can set any of LANG,
LC_CTYPE, or LC_ALL to a UTF-8 locale to fix plain 'ls'.

-- 
You are receiving this mail because:
You are the assignee for the bug.


More information about the freebsd-bugs mailing list