aboutsummaryrefslogtreecommitdiff
path: root/malloc
diff options
context:
space:
mode:
authorUlrich Drepper <drepper@redhat.com>2002-12-31 08:00:19 +0000
committerUlrich Drepper <drepper@redhat.com>2002-12-31 08:00:19 +0000
commit416d2de60b8e567ac7cd6a581afba0f5cdfc932e (patch)
treeabd37640e253dae0e65751ea12f20253830bb269 /malloc
parent89d6e4445954aee95d02b84db7af7fa0cca93195 (diff)
downloadglibc-416d2de60b8e567ac7cd6a581afba0f5cdfc932e.tar
glibc-416d2de60b8e567ac7cd6a581afba0f5cdfc932e.tar.gz
glibc-416d2de60b8e567ac7cd6a581afba0f5cdfc932e.tar.bz2
glibc-416d2de60b8e567ac7cd6a581afba0f5cdfc932e.zip
Update.
2002-12-30 Ulrich Drepper <drepper@redhat.com> * malloc/thread-m.h (thread_atfork): Define using __register_atfork.
Diffstat (limited to 'malloc')
-rw-r--r--malloc/thread-m.h8
1 files changed, 7 insertions, 1 deletions
diff --git a/malloc/thread-m.h b/malloc/thread-m.h
index 49db784c52..d3352d1fe5 100644
--- a/malloc/thread-m.h
+++ b/malloc/thread-m.h
@@ -72,8 +72,14 @@ __libc_lock_define (typedef, mutex_t)
#endif
+/* This is defined by newer gcc version unique for each module. */
+extern void *__dso_handle __attribute__ ((__weak__));
+
+#include <fork.h>
+
#define thread_atfork(prepare, parent, child) \
- (__pthread_atfork != NULL ? __pthread_atfork(prepare, parent, child) : 0)
+ __register_atfork (prepare, parent, child, \
+ &__dso_handle == NULL ? NULL : __dso_handle)
#elif defined(MUTEX_INITIALIZER)
/* Assume hurd, with cthreads */