From e1de8e3c33257b4e7d6b98767a67414efc31b6c7 Mon Sep 17 00:00:00 2001 From: rpj Date: Fri, 4 Mar 2011 08:03:46 +0000 Subject: Casting fixups --- tests/rwlock6_t.c | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) (limited to 'tests/rwlock6_t.c') diff --git a/tests/rwlock6_t.c b/tests/rwlock6_t.c index 37a332a..f8a05f1 100644 --- a/tests/rwlock6_t.c +++ b/tests/rwlock6_t.c @@ -67,17 +67,17 @@ void * rdfunc(void * arg) PTW32_FTIME(&currSysTime); - abstime.tv_sec = currSysTime.time; + abstime.tv_sec = (long)currSysTime.time; abstime.tv_nsec = NANOSEC_PER_MILLISEC * currSysTime.millitm; - if ((int) arg == 1) + if ((int) (size_t)arg == 1) { abstime.tv_sec += 1; assert(pthread_rwlock_timedrdlock(&rwlock1, &abstime) == ETIMEDOUT); ba = 0; } - else if ((int) arg == 2) + else if ((int) (size_t)arg == 2) { abstime.tv_sec += 3; assert(pthread_rwlock_timedrdlock(&rwlock1, &abstime) == 0); @@ -110,10 +110,10 @@ main() Sleep(500); assert(pthread_create(&rdt2, NULL, rdfunc, (void *) 2) == 0); - assert(pthread_join(wrt1, (void **) &wr1Result) == 0); - assert(pthread_join(rdt1, (void **) &rd1Result) == 0); - assert(pthread_join(wrt2, (void **) &wr2Result) == 0); - assert(pthread_join(rdt2, (void **) &rd2Result) == 0); + assert(pthread_join(wrt1, (void *) &wr1Result) == 0); + assert(pthread_join(rdt1, (void *) &rd1Result) == 0); + assert(pthread_join(wrt2, (void *) &wr2Result) == 0); + assert(pthread_join(rdt2, (void *) &rd2Result) == 0); assert(wr1Result == 10); assert(rd1Result == 0); -- cgit v1.2.3