Skip site navigation (1)Skip section navigation (2)
Date:      Mon, 02 Jul 2018 17:36:36 +0900
From:      =?utf-8?B?5b6M6Jek5aSn5Zyw?= <daichigoto@icloud.com>
To:        Hiroki Sato <hrs@FreeBSD.org>
Cc:        lists@eitanadler.com, daichi@freebsd.org, gnn@FreeBSD.org, cem@freebsd.org, src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org
Subject:   Re: svn commit: r335836 - head/usr.bin/top
Message-ID:  <459BD898-8072-426E-A968-96C1382AC616@icloud.com>
In-Reply-To: <20180702.155529.1102410939281120947.hrs@allbsd.org>
References:  <201807010532.w615W44e042172@repo.freebsd.org> <CAG6CVpXvic6y6VLEjBzxFtdQC=6b_%2BC2CmEvpMssgYEahAZhOQ@mail.gmail.com> <CAF6rxg=Zjkf6EbSgt1fBQBUDHGKWwLf=n9ZJweJH%2BDi800kJ3w@mail.gmail.com> <20180702.155529.1102410939281120947.hrs@allbsd.org>

next in thread | previous in thread | raw e-mail | index | archive | help


> 2018/07/02 15:55=E3=80=81Hiroki Sato <hrs@FreeBSD.org>=E3=81=AE=E3=83=A1=
=E3=83=BC=E3=83=AB:
>=20
> Eitan Adler <lists@eitanadler.com> wrote
>  in =
<CAF6rxg=3DZjkf6EbSgt1fBQBUDHGKWwLf=3Dn9ZJweJH+Di800kJ3w@mail.gmail.com>:
>=20
> li> On 1 July 2018 at 10:08, Conrad Meyer <cem@freebsd.org> wrote:
> li> > Hi Daichi,
> li> >
> li> >
> li> >
> li> > I don't think code to decode UTF-8 belongs in top(1).  I don't =
know
> li> > what the goal of this routine is, but I doubt this is the right =
way to
> li> > accomplish it.
> li>
> li> For the record, I agree. This is why I didn't click "accept" on =
the
> li> revision. I don't fully oppose leaving it in top(1) for now as we =
work
> li> out the API, but long term its the wrong place.
> li>
> li> https://reviews.freebsd.org/D16058 is the review.
>=20
> I strongly object this kind of encoding-specific routine.  Please
> back out it.  The problem is that top(1) does not support multibyte
> encoding in functions for printing, and using C99 wide/multibyte
> character manipulation API such as iswprint(3) is the way to solve
> it.  Doing getenv("LANG") and assuming an encoding based on it is a
> very bad practice to internationalize software.
>=20
> -- Hiroki

I respect what you mean.

Once I back out, I will begin implementing it in a different way.
Please advise which function should be used for implementation
(iswprint (3) and what other functions should be used?)

Best regards,
Daichi=



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?459BD898-8072-426E-A968-96C1382AC616>