#include <sys/param.h>
#include <sys/time.h>
#include <sys/wait.h> /* for waitpid macros */
+#include <locale.h> /* for __uselocale */
#include <ldsodefs.h>
#include "pthread.h"
__sched_setscheduler(THREAD_GETMEM(self, p_pid),
SCHED_OTHER, &default_params);
}
+#if !(USE_TLS && HAVE___THREAD) && defined SHARED
+ /* Initialize thread-locale current locale to point to the global one.
+ With __thread support, the variable's initializer takes care of this. */
+ __uselocale (LC_GLOBAL_LOCALE);
+#endif
/* Make gdb aware of new thread */
if (__pthread_threads_debug && __pthread_sig_debug > 0) {
request.req_thread = self;
#include "restart.h"
#include <ldsodefs.h>
#include <tls.h>
+#include <locale.h> /* for __uselocale */
/* Sanity check. */
#if __ASSUME_REALTIME_SIGNALS && !defined __SIGRTMIN
__pthread_initial_thread.p_cpuclock_offset = GL(dl_cpuclock_offset);
# endif
#endif
+
+#if !(USE_TLS && HAVE___THREAD) && defined SHARED
+ /* Initialize thread-locale current locale to point to the global one.
+ With __thread support, the variable's initializer takes care of this. */
+ __uselocale (LC_GLOBAL_LOCALE);
+#endif
}