Merged the pthread_attr_setscope build problem fix into NSPRPUB_RELEASE_3_1_BRANCH
authorwtc%netscape.com
Tue, 06 Apr 1999 01:11:58 +0000
branchNSPRPUB_RELEASE_3_1_BRANCH
changeset 535 dfbfdb731fb3302141247305f2137631a2945c01
parent 534 709be8e17ebf28bce01948f3a82984a2e4fc8b4d
child 538 32faf681f6136cb7a03dab201fb47405615f46ca
push idunknown
push userunknown
push dateunknown
Merged the pthread_attr_setscope build problem fix into NSPRPUB_RELEASE_3_1_BRANCH.
pr/src/pthreads/ptthread.c
--- a/pr/src/pthreads/ptthread.c
+++ b/pr/src/pthreads/ptthread.c
@@ -309,20 +309,17 @@ static PRThread* _PR_CreateThread(
         thred->priority = priority;
         if (PR_UNJOINABLE_THREAD == state)
             thred->state |= PT_THREAD_DETACHED;
 
         if (PR_LOCAL_THREAD == scope)
         	scope = PR_GLOBAL_THREAD;
 			
         if (PR_GLOBAL_BOUND_THREAD == scope) {
-			/*
-			 * should a Posix feature test be used here?
-			 */
-#ifdef PTHREAD_SCOPE_SYSTEM
+#if defined(_POSIX_THREAD_PRIORITY_SCHEDULING)
     		rv = pthread_attr_setscope(&tattr, PTHREAD_SCOPE_SYSTEM);
 			if (rv) {
 				/*
 				 * system scope not supported
 				 */
         		scope = PR_GLOBAL_THREAD;
 				/*
 				 * reset scope