summaryrefslogtreecommitdiff
path: root/tests/condvar3.c
diff options
context:
space:
mode:
Diffstat (limited to 'tests/condvar3.c')
-rw-r--r--tests/condvar3.c8
1 files changed, 7 insertions, 1 deletions
diff --git a/tests/condvar3.c b/tests/condvar3.c
index 673feb5..ef71946 100644
--- a/tests/condvar3.c
+++ b/tests/condvar3.c
@@ -59,13 +59,19 @@ enum {
void *
mythread(void * arg)
{
+ int result = 0;
+
assert(pthread_mutex_lock(&mutex) == 0);
shared++;
assert(pthread_mutex_unlock(&mutex) == 0);
- assert(pthread_cond_signal(&cv) == 0);
+ if ((result = pthread_cond_signal(&cv)) != 0)
+ {
+ printf("Error = %s\n", error_string[result]);
+ }
+ assert(result == 0);
return (void *) 0;
}