"display charset" vs. Unix locales

Steve Langasek vorlon at netexpress.net
Sat May 31 15:33:54 GMT 2003


On Sat, May 31, 2003 at 03:44:12AM -0400, Michael B Allen wrote:
> On Fri, 23 May 2003, Steve Langasek wrote:

> > One curious side-effect is that the default for display charset is
> > "ASCII", but glibc's nl_langinfo() returns "ANSI_X3.4-1968" as the
> > character set for the C locale.  This results in C locale conversions

> This is because you must first initialize the locale with
> setlocale(LC_CTYPE, ""). Then it will say ASCII.

See the patch.  Glibc does *not* use the name "ASCII" for this character
set -- this is known.  The side-effect is that changing the name of the
character set results in different handling by Samba, which recognizes
"ASCII" as a special name and processes it internally.

> Actually it will probably say ISO-8859-1.

If anything ever says that in the *C* locale, it's a bug.

-- 
Steve Langasek
postmodern programmer
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 189 bytes
Desc: not available
Url : http://lists.samba.org/archive/samba-technical/attachments/20030531/2708ef0c/attachment.bin


More information about the samba-technical mailing list