]> granicus.if.org Git - php/commitdiff
- MFH: make setlocale thread only, drastically reduce TS related crashes in error...
authorPierre Joye <pajoye@php.net>
Wed, 16 Mar 2011 23:54:14 +0000 (23:54 +0000)
committerPierre Joye <pajoye@php.net>
Wed, 16 Mar 2011 23:54:14 +0000 (23:54 +0000)
main/SAPI.c

index c56676c3c543030aefbf9e9d220c6d0736bc956f..32133396347517646f18d5256aefbe635a544b15 100644 (file)
@@ -78,6 +78,9 @@ SAPI_API void sapi_startup(sapi_module_struct *sf)
 
 #ifdef ZTS
        ts_allocate_id(&sapi_globals_id, sizeof(sapi_globals_struct), (ts_allocate_ctor) sapi_globals_ctor, (ts_allocate_dtor) sapi_globals_dtor);
+# ifdef PHP_WIN32
+       _configthreadlocale(_ENABLE_PER_THREAD_LOCALE);
+# endif
 #else
        sapi_globals_ctor(&sapi_globals);
 #endif