Current-Users archive

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

Re: sh command bogus output in UTF-8 text



On Thu, 6 Feb 2020 at 06:36, Jun Ebihara <jun%soum.co.jp@localhost> wrote:
>
> On NetBSD 9.99.42 NetBSD 9.99.42 (GENERIC) #0:
> Tue Jan 28 13:08:40 UTC 2020  mkrepro%mkrepro.NetBSD.org@localhost:/usr/src/sys/arch/amd64/compile/GENERIC amd64
>
> http://ftp.netbsd.org/pub/NetBSD/misc/jun/sh-command-utf8-testing
>
> cat seems fine,e3-81-ab -> e3-81-ab
> amibase: {53} cat sh-command-utf8-testing |od -ax
> 0000000    c   a   t  sp   <   <  sp   E   O   F  nl  sp  sp  e3  81  ab
>    6163    2074    3c3c    4520    464f    200a    e320    ab81
> 0000020   nl   E   O   F  nl
>    450a    464f    000a
> 0000025
>
> sh seems broken,e3-81-ab -> e3-81-81-ab
> amibase: {54} sh sh-command-utf8-testing | od -ax
> 0000000   sp  sp  e3  81  81  ab  nl
>    2020    81e3    ab81    000a
> 0000007
>
> csh returns good ,e3-81-ab -> e3-81-ab
> amibase: {55} csh sh-command-utf8-testing | od -ax
> 0000000   sp  sp  e3  81  ab  nl
>    2020    81e3    0aab
> 0000006
>
> --
> Jun Ebihara

Another example - with cyrillic:

$ ksh bg-testing
に кирилица
$ csh bg-testing
に кирилица
$ bash bg-testing
に кирилица
$ zsh bg-testing
に кирилица
$ sh bg-testing
ぁ кирилиса

Чавдар


-- 
----


Home | Main Index | Thread Index | Old Index