This is the mail archive of the
libc-alpha@sources.redhat.com
mailing list for the glibc project.
Re: LC_MESSAGES problem ?
wkpark <wkpark@chem.skku.ac.kr> writes:
> It so hard to conversation :-(
>
> with utf8 locale(like ko_KR.utf8), does automatic translation working correct
> with setlocale(LC_MESSAGES,"") only program ??
Of course not because you are not using the locale. Using a locale
means using all of the categories. As Paul already explained, mixing
categories from different locales is possible but the behavior is
undefined. Especially the LC_CTYPE category must always match the the
categories you are using.
> errno=2;
> // setlocale(LC_CTYPE, "");
> setlocale(LC_MESSAGES, "");
> perror("aaa");
> return 1;
> }
This program could do whatever it wants, start nethack, format your
harddisk, whatever. Its behavior is undefined.
--
---------------. ,-. 1325 Chesapeake Terrace
Ulrich Drepper \ ,-------------------' \ Sunnyvale, CA 94089 USA
Red Hat `--' drepper at redhat.com `------------------------