summaryrefslogtreecommitdiff
path: root/lib/libpthread/thread/thr_create.c
diff options
context:
space:
mode:
authorJohn Birrell <jb@FreeBSD.org>1998-04-11 07:47:22 +0000
committerJohn Birrell <jb@FreeBSD.org>1998-04-11 07:47:22 +0000
commitd60f0fa60da3004a1b2fb533afd6a7aa790795e3 (patch)
treeebe8fdb4866ab709d5d0db2d85c87328cea7307a /lib/libpthread/thread/thr_create.c
parentec216c263498f3ab7c5554f5c5571125b57024b8 (diff)
Notes
Diffstat (limited to 'lib/libpthread/thread/thr_create.c')
-rw-r--r--lib/libpthread/thread/thr_create.c7
1 files changed, 7 insertions, 0 deletions
diff --git a/lib/libpthread/thread/thr_create.c b/lib/libpthread/thread/thr_create.c
index 3dcd944bced9..c9c6c9fb6d42 100644
--- a/lib/libpthread/thread/thr_create.c
+++ b/lib/libpthread/thread/thr_create.c
@@ -40,6 +40,7 @@
#include <machine/reg.h>
#include <pthread.h>
#include "pthread_private.h"
+#include "libc_private.h"
int
_thread_create(pthread_t * thread, const pthread_attr_t * attr,
@@ -254,6 +255,12 @@ pthread_create(pthread_t * thread, const pthread_attr_t * attr,
int ret = 0;
/*
+ * Locking functions in libc are required when there are
+ * threads other than the initial thread.
+ */
+ __isthreaded = 1;
+
+ /*
* Call the low level thread creation function which allows a parent
* thread to be specified:
*/