2003-12-10 Ulrich Drepper <drepper@redhat.com>
* sysdeps/pthread/bits/libc-lock.h (__rtld_lock_initialize): Define.
* sysdeps/unix/sysv/linux/fork.c (__libc_fork): Call
__rtld_lock_initialize for ld.so lock.
Patch in part by Adam Li <adam.li@intel.com>.
+2003-12-10 Ulrich Drepper <drepper@redhat.com>
+
+ * sysdeps/pthread/bits/libc-lock.h (__rtld_lock_initialize): Define.
+ * sysdeps/unix/sysv/linux/fork.c (__libc_fork): Call
+ __rtld_lock_initialize for ld.so lock.
+ Patch in part by Adam Li <adam.li@intel.com>.
+
2003-12-02 David Mosberger <davidm@hpl.hp.com>
* Makefile (link-libc-static): Remove -lgcc_eh---it's already mentioned
#define _RTLD_LOCK_RECURSIVE_INITIALIZER \
{PTHREAD_RECURSIVE_MUTEX_INITIALIZER_NP}
+#define __rtld_lock_initialize(NAME) \
+ (void) ((NAME) = (__rtld_lock_recursive_t) _RTLD_LOCK_RECURSIVE_INITIALIZER)
+
/* If we check for a weakly referenced symbol and then perform a
normal jump to it te code generated for some platforms in case of
PIC is unnecessarily slow. What would happen is that the function
/* Reset locks in the I/O code. */
_IO_list_resetlock ();
+ /* Reset the lock the dynamic loader uses to protect its data. */
+ __rtld_lock_initialize (GL(dl_load_lock));
+
/* Run the handlers registered for the child. */
while (allp != NULL)
{