From 94db4dd759dc22f1927f945a3611281d99ebbdf4 Mon Sep 17 00:00:00 2001 From: Daniel Eischen Date: Wed, 5 Nov 2003 18:18:45 +0000 Subject: [PATCH] Don't declare the malloc lock; use the declaration provided in libc. Noticed by: bde --- lib/libkse/thread/thr_fork.c | 7 ++++++- lib/libpthread/thread/thr_fork.c | 7 ++++++- 2 files changed, 12 insertions(+), 2 deletions(-) diff --git a/lib/libkse/thread/thr_fork.c b/lib/libkse/thread/thr_fork.c index 6989174509e..401aae9e188 100644 --- a/lib/libkse/thread/thr_fork.c +++ b/lib/libkse/thread/thr_fork.c @@ -39,9 +39,14 @@ #include #include #include + +#include "libc_private.h" #include "thr_private.h" -extern spinlock_t *__malloc_lock; +/* + * For a while, allow libpthread to work with a libc that doesn't + * export the malloc lock. + */ #pragma weak __malloc_lock __weak_reference(_fork, fork); diff --git a/lib/libpthread/thread/thr_fork.c b/lib/libpthread/thread/thr_fork.c index 6989174509e..401aae9e188 100644 --- a/lib/libpthread/thread/thr_fork.c +++ b/lib/libpthread/thread/thr_fork.c @@ -39,9 +39,14 @@ #include #include #include + +#include "libc_private.h" #include "thr_private.h" -extern spinlock_t *__malloc_lock; +/* + * For a while, allow libpthread to work with a libc that doesn't + * export the malloc lock. + */ #pragma weak __malloc_lock __weak_reference(_fork, fork);