Skip to content

Commit

Permalink
Declare _errno, _h_errno, and _res unless we use TLS internally.
Browse files Browse the repository at this point in the history
  • Loading branch information
Ulrich Drepper committed Aug 3, 2002
1 parent b50fca0 commit 04a7ed7
Showing 1 changed file with 11 additions and 9 deletions.
20 changes: 11 additions & 9 deletions linuxthreads/pthread.c
Original file line number Diff line number Diff line change
Expand Up @@ -38,23 +38,25 @@
# error "This must not happen; new kernel assumed but old headers"
#endif

#ifdef USE_TLS

/* We need only a few variables. */
static pthread_descr manager_thread;

#else

#if !(USE_TLS && HAVE___THREAD)
/* These variables are used by the setup code. */
extern int _errno;
extern int _h_errno;

/* We need the global/static resolver state here. */
#include <resolv.h>
#undef _res
# include <resolv.h>
# undef _res
#endif

extern struct __res_state _res;

#ifdef USE_TLS

/* We need only a few variables. */
static pthread_descr manager_thread;

#else

/* Descriptor of the initial thread */

struct _pthread_descr_struct __pthread_initial_thread = {
Expand Down

0 comments on commit 04a7ed7

Please sign in to comment.