This is the mail archive of the
mailing list for the Cygwin project.
Re: bash and the current locale implementation
2009/10/1 Corinna Vinschen:
>> > Consequentially, bash can't just call setlocale (LC_ALL, ""). ÂInstead,
>> > bash calls the following:
>> > Â setlocale (LC_CTYPE, "foo");
>> > Â setlocale (LC_NUMERIC, "foo");
>> > Â setlocale (LC_TIME, "foo");
>> > Â [...]
>> I'll see if I can find some way to patch bash.
> Âsetenv (locale_var);
> Âif (locale_var == "LANG" || "LC_ALL")
> Â Âsetlocale (LC_ALL, "");
> Âelse if (locale_var == "LC_CTYPE")
> Â Âsetlocale (LC_CTYPE, "");
> would be sufficient. ÂBut I can't say I'm really happy about this. ÂIt
> sure sounds like a hack, having to change bash. ÂUnfortunately I can't
> see any way to change Cygwin as long as the application doesn't change
> its own environment.
I'm confused. I thought setlocale() wasn't meant to change Cygwin
internals aymore, because that would require all apps to call
setlocale(LC_CTYPE, "")? You'd cited ssh as an example that doesn't do