summaryrefslogtreecommitdiff
path: root/nptl/sysdeps/unix/sysv/linux/libc_pthread_init.c
diff options
context:
space:
mode:
authorUlrich Drepper <drepper@redhat.com>2002-12-19 07:09:42 +0000
committerUlrich Drepper <drepper@redhat.com>2002-12-19 07:09:42 +0000
commitdf45b31e8150087fad9ff5889fe1a95054e26730 (patch)
tree5c3489fd9de8f22f9386144daea297828d00bd7a /nptl/sysdeps/unix/sysv/linux/libc_pthread_init.c
parent5e2891795021a78fb975c55377d05919f4dae0c0 (diff)
Update.
2002-12-18 Ulrich Drepper <drepper@redhat.com> * descr.h (struct pthread) [NEED_DL_SYSINFO]: Add sysinfo member. * sysdeps/i386/tls.h (tcbhead_t): Add sysinfo member. Define SYSINFO_OFFSEET if NEED_DL_SYSINFO is defined. (INIT_SYSINFO): New #define. (TLS_TP_INIT): Use INIT_SYSINFO. * sysdeps/unix/sysv/linux/libc_pthread_init.c (__libc_pthread_init): At test to make sure SYSINFO_OFFSET value is correct. * sysdeps/unix/sysv/linux/i386/dl-sysdep.h: New file.
Diffstat (limited to 'nptl/sysdeps/unix/sysv/linux/libc_pthread_init.c')
-rw-r--r--nptl/sysdeps/unix/sysv/linux/libc_pthread_init.c9
1 files changed, 9 insertions, 0 deletions
diff --git a/nptl/sysdeps/unix/sysv/linux/libc_pthread_init.c b/nptl/sysdeps/unix/sysv/linux/libc_pthread_init.c
index 7d91528aaf..87c97343b0 100644
--- a/nptl/sysdeps/unix/sysv/linux/libc_pthread_init.c
+++ b/nptl/sysdeps/unix/sysv/linux/libc_pthread_init.c
@@ -20,6 +20,7 @@
#include <unistd.h>
#include <list.h>
#include "fork.h"
+#include <dl-sysdep.h>
#include <tls.h>
#include <string.h>
#include <pthreadP.h>
@@ -62,4 +63,12 @@ __libc_pthread_init (ptr, reclaim, functions)
str_n_len ("*** MULTIPLE_THREADS_OFFSET out of date\n"));
_exit (1);
}
+#ifdef SYSINFO_OFFSET
+ if (offsetof (struct pthread, header.data.sysinfo) != SYSINFO_OFFSET)
+ {
+ __libc_write (STDERR_FILENO,
+ str_n_len ("*** SYSINFO_OFFSET out of date\n"));
+ _exit (1);
+ }
+#endif
}