]> git.rm.cloudns.org Git - xonotic/netradiant.git/commitdiff
pthread_join Fix from Nerius Landys
authornamespace <namespace@8a3a26a2-13c4-0310-b231-cf6edde360e5>
Sat, 13 Nov 2010 13:36:27 +0000 (13:36 +0000)
committernamespace <namespace@8a3a26a2-13c4-0310-b231-cf6edde360e5>
Sat, 13 Nov 2010 13:36:27 +0000 (13:36 +0000)
git-svn-id: https://zerowing.idsoftware.com/svn/radiant/GtkRadiant/trunk@333 8a3a26a2-13c4-0310-b231-cf6edde360e5

tools/quake3/common/threads.c

index abdf2055d286d554d30b1831e3cd273314f10d9c..2e5e903260d06c0af3c1b346251bf357b53ee623 100644 (file)
@@ -520,7 +520,8 @@ void RunThreadsOn (int workcnt, qboolean showpacifier, void(*func)(int))
   pthread_t work_threads[MAX_THREADS];
   
   int    start, end;
-  int   i=0, status=0;
+  int   i=0;
+  void *exit_value;
   
   start     = I_FloatTime ();
   pacifier  = showpacifier;
@@ -556,7 +557,7 @@ void RunThreadsOn (int workcnt, qboolean showpacifier, void(*func)(int))
     }
     for (i=0 ; i<numthreads ; i++)
     {
-      if(pthread_join(work_threads[i], (void **)&status) != 0)
+      if(pthread_join(work_threads[i], &exit_value) != 0)
         Error("pthread_join failed");
     }
     pthread_mutexattr_destroy(&mattrib);