-/* Copyright (C) 1991,92,93,94,95,96,97,98,99,2000,01
+/* Copyright (C) 1991,92,93,94,95,96,97,98,99,2000,01,2002
Free Software Foundation, Inc.
This file is part of the GNU C Library.
#include "hurdfault.h"
#include "hurdmalloc.h" /* XXX */
+#include "../locale/localeinfo.h"
const char *_hurdsig_getenv (const char *);
malloc (__hurd_threadvar_max * sizeof (unsigned long int));
if (__hurd_sigthread_variables == NULL)
__libc_fatal ("hurd: Can't allocate threadvars for signal thread\n");
+ memset (__hurd_sigthread_variables, 0,
+ __hurd_threadvar_max * sizeof (unsigned long int));
+ __hurd_sigthread_variables[_HURD_THREADVAR_LOCALE]
+ = (unsigned long int) &_nl_global_locale;
/* Reinitialize the MiG support routines so they will use a per-thread
variable for the cached reply port. */
#else
__libc_tsd_define (, LOCALE)
/* This is a bad kludge presuming the variable name used by the macros.
- Using typeof makes sure to barf if we do not match the macro definition. */
+ Using typeof makes sure to barf if we do not match the macro definition.
+ This ifndef is a further bad kludge for Hurd, where there is an explicit
+ initialization. */
+# ifndef _HURD_THREADVAR_H
__typeof (__libc_tsd_LOCALE_data) __libc_tsd_LOCALE_data = &_nl_global_locale;
+# endif
#endif