summaryrefslogtreecommitdiff
path: root/tests/rwlock7.c
diff options
context:
space:
mode:
authorrpj <rpj>2001-02-08 16:31:20 +0000
committerrpj <rpj>2001-02-08 16:31:20 +0000
commit2b3eede0b834a82c7dce5ec328f3929c0effc536 (patch)
tree24414750f16e0c7bc7d231139d7f20a76b512ae4 /tests/rwlock7.c
parent3c0fbfafe563b7b312d60c42c0d58a3a1f4d5930 (diff)
Fixes to new mutex routines and various tests.exp-2001-02-09-passed
Diffstat (limited to 'tests/rwlock7.c')
-rw-r--r--tests/rwlock7.c11
1 files changed, 5 insertions, 6 deletions
diff --git a/tests/rwlock7.c b/tests/rwlock7.c
index 88abcfe..cf20bfd 100644
--- a/tests/rwlock7.c
+++ b/tests/rwlock7.c
@@ -27,9 +27,9 @@ typedef struct thread_tag {
* Read-write lock and shared data
*/
typedef struct data_tag {
- rwlock_t lock;
- int data;
- int updates;
+ pthread_rwlock_t lock;
+ int data;
+ int updates;
} data_t;
static thread_t threads[THREADS];
@@ -99,10 +99,9 @@ main (int argc, char *argv[])
{
int count;
int data_count;
- int status;
- unsigned int seed = 1;
int thread_updates = 0;
int data_updates = 0;
+ int seed = 1;
struct _timeb currSysTime1;
struct _timeb currSysTime2;
@@ -115,7 +114,7 @@ main (int argc, char *argv[])
data[data_count].data = 0;
data[data_count].updates = 0;
- assert(pthread_rwlock_init (&data[data_count].lock) == 0);
+ assert(pthread_rwlock_init (&data[data_count].lock, NULL) == 0);
}
_ftime(&currSysTime1);