Doyon, Jean-Francois wrote at 2006-12-15 08:38 -0500: >setlocale() is a python thing. It wraps a C library, and that function >setups an application wide environment (A bit like an environment >variable would ...) ... Which is why it's not thread safe.
If you do not have a thread aware implementation of "setlocale", then it is *VERY* dangerous to change "setlocale" inside a thread -- as changing any global data can lead to non-deterministic behaviour in a multi-threaded environment unless special precautions (locking) are taken. Apparently, you are aware of the danger. But, I have not seen how you avoid the problem in your sketched solution. -- Dieter _______________________________________________ Zope maillist - [email protected] http://mail.zope.org/mailman/listinfo/zope ** No cross posts or HTML encoding! ** (Related lists - http://mail.zope.org/mailman/listinfo/zope-announce http://mail.zope.org/mailman/listinfo/zope-dev )
