summaryrefslogtreecommitdiff
path: root/lib/libpthread/thread/thr_create.c
diff options
context:
space:
mode:
authorDaniel Eischen <deischen@FreeBSD.org>2004-08-12 12:12:12 +0000
committerDaniel Eischen <deischen@FreeBSD.org>2004-08-12 12:12:12 +0000
commitb9de27c0051bd9c4ce167327b5824a31baee1474 (patch)
treef5cde2cd4e3f3ec2684cfd283ab1b57e8981d4b1 /lib/libpthread/thread/thr_create.c
parent313745d2ade8bb7c2d9c8cd7040732228e54843b (diff)
Notes
Diffstat (limited to 'lib/libpthread/thread/thr_create.c')
-rw-r--r--lib/libpthread/thread/thr_create.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/lib/libpthread/thread/thr_create.c b/lib/libpthread/thread/thr_create.c
index 8c4592af7e8e..54bcd3b0780e 100644
--- a/lib/libpthread/thread/thr_create.c
+++ b/lib/libpthread/thread/thr_create.c
@@ -126,8 +126,11 @@ _pthread_create(pthread_t * thread, const pthread_attr_t * attr,
*/
}
}
- if (_thread_scope_system != 0)
+ if (_thread_scope_system > 0)
new_thread->attr.flags |= PTHREAD_SCOPE_SYSTEM;
+ else if ((_thread_scope_system < 0)
+ && (thread != &_thr_sig_daemon))
+ new_thread->attr.flags &= ~PTHREAD_SCOPE_SYSTEM;
if (create_stack(&new_thread->attr) != 0) {
/* Insufficient memory to create a stack: */
ret = EAGAIN;