It does not actually need to be extern any more.
GLIBC_PRIVATE {
__libc_alloca_cutoff;
__libc_pthread_init;
- __pthread_cleanup_stack;
__pthread_total;
___pthread_self;
__pthread_alloc;
#include <string.h>
#include <pthread-functions.h>
-__thread struct __pthread_cancelation_handler *__pthread_cleanup_stack;
-
void
__libc_pthread_init (const struct pthread_functions *functions)
{
#include <pt-internal.h>
#include <shlib-compat.h>
+static __thread struct __pthread_cancelation_handler *__pthread_cleanup_stack;
+
struct __pthread_cancelation_handler **
___pthread_get_cleanup_stack (void)
{
#ifndef _pthread_self
extern struct __pthread *_pthread_self (void);
#endif
-
-/* Stores the stack of cleanup handlers for the thread. */
-extern __thread struct __pthread_cancelation_handler *__pthread_cleanup_stack;
\f
/* Initialize the pthreads library. */