X-Recipient: archive-cygwin AT delorie DOT com X-SWARE-Spam-Status: No, hits=-1.7 required=5.0 tests=AWL,BAYES_00,DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,FREEMAIL_FROM,RCVD_IN_DNSWL_NONE,T_TO_NO_BRKTS_FREEMAIL X-Spam-Check-By: sourceware.org MIME-Version: 1.0 In-Reply-To: <4C854E45.5020103@towo.net> References: <20100906090751 DOT GB13174 AT calimero DOT vinschen DOT de> <4C854E45 DOT 5020103 AT towo DOT net> Date: Tue, 7 Sep 2010 06:32:01 +0100 Message-ID: Subject: Re: LC_ALL=ru_RU.cp1251 ls -l encoding problem. From: Andy Koppe To: cygwin AT cygwin DOT com Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable X-IsSubscribed: yes Mailing-List: contact cygwin-help AT cygwin DOT com; run by ezmlm Precedence: bulk List-Id: List-Unsubscribe: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: cygwin-owner AT cygwin DOT com Mail-Followup-To: cygwin AT cygwin DOT com Delivered-To: mailing list cygwin AT cygwin DOT com On 6 September 2010 21:25, Thomas Wolff wrote: > =C2=A0Am 06.09.2010 11:07, schrieb Corinna Vinschen: >> >> On Sep =C2=A05 21:16, Oleksandr Gavenko wrote: >>> >>> As you can see user/group always printed in UTF-8 >>> and discard LC_ALL=3Dcp1251. >>> >>> =C2=A0 $ LC_ALL=3Dru_RU.cp1251 mintty >> >> The problem is, what is the encoding of the /etc/passwd file itself? >> If it's UTF-8, it's UTF-8. =C2=A0If you want to use another encoding >> throughout, you would have to generate the /etc/passwd and /etc/group >> files in that other encoding as well. > > Which is a problem if different users have different locale preferences, = and > also a problem to configure for non-experts. True, but you'd get the same problem on Linux, i.e. it's basically assumed that the same encoding is used across the whole system (and UTF-8 is the only sensible choice for that, except in limited circumstances). That doesn't need to stop Cygwin from doing better, though, as of course it does with filenames already. > What about making the functions that access user/group information aware = of > this, i.e. interpreting the files as UTF-8 and interpreting > parameters/results according to current locale? > (getpwuid, getpwnam, getlogin, ...) Makes sense, me thinks. Andy -- Problem reports: http://cygwin.com/problems.html FAQ: http://cygwin.com/faq/ Documentation: http://cygwin.com/docs.html Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple