2004-08-11 Jakub Jelinek <jakub@redhat.com>
authorroland <roland>
Wed, 11 Aug 2004 18:48:48 +0000 (18:48 +0000)
committerroland <roland>
Wed, 11 Aug 2004 18:48:48 +0000 (18:48 +0000)
* tst-rwlock14.c (tf): Read main thread handle from *ARG
before pthread_barrier_wait.

nptl/tst-rwlock14.c

index b9611a8..fc0d3d2 100644 (file)
@@ -38,12 +38,12 @@ tf (void *arg)
       exit (EXIT_FAILURE);
     }
 
-  pthread_barrier_wait (&b);
+  pthread_t mt = *(pthread_t *) arg;
 
-  pthread_t *mtp = (pthread_t *) arg;
+  pthread_barrier_wait (&b);
 
   /* This call will never return.  */
-  pthread_join (*mtp, NULL);
+  pthread_join (mt, NULL);
 
   return NULL;
 }