--- a/tests/condvar6.c
+++ b/tests/condvar6.c
@@ -149,7 +149,7 @@
 
   cvthing.shared = 0;
 
-  assert((t[0] = pthread_self()) != NULL);
+  assert((t[0] = pthread_self()).p != NULL);
 
   assert(cvthing.notbusy == PTHREAD_COND_INITIALIZER);
 
@@ -164,7 +164,7 @@
 
   abstime.tv_sec += 5;
 
-  assert((t[0] = pthread_self()) != NULL);
+  assert((t[0] = pthread_self()).p != NULL);
 
   awoken = 0;