On Apr 6 09:06, Charles Wilson wrote: > Corinna Vinschen wrote: > > > However, just before the application's main() is called, the locale is > > set back to "C", see > > http://cygwin.com/cgi-bin/cvsweb.cgi/src/winsup/cygwin/dcrt0.cc.diff?r1=1.352&r2=1.353&cvsroot=src&f=h > > Hmm. "before main()" huh? Is that *before*, or *after*, C++ static > initializers are called? If it's after, then that could be a problem, > at least for languages that support such things. (C++, Java?)
The global ctors functions are called before the environment is initialized. In that state the locale is always "C". Note that the locale is only changed temporarily when the environment is read from a non-Cygwin parent. This doesn't affect forked Cygwin processes, nor Cygwin processes exec'ed from a Cygwin parent. Corinna -- Corinna Vinschen Please, send mails regarding Cygwin to Cygwin Project Co-Leader cygwin AT cygwin DOT com Red Hat -- Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple Problem reports: http://cygwin.com/problems.html Documentation: http://cygwin.com/docs.html FAQ: http://cygwin.com/faq/