summaryrefslogtreecommitdiff
path: root/sync.c
diff options
context:
space:
mode:
authorrpj <rpj>1998-07-25 15:46:04 +0000
committerrpj <rpj>1998-07-25 15:46:04 +0000
commitd2298ecbc9910e9186dad3eeb7fa8eed7bca9a80 (patch)
tree70b888de3962c85cd93d6fcef87fcd05f9e35c4d /sync.c
parent9ec682372a4f13353f7437fcffd48b75b5489a8f (diff)
Sun Jul 26 00:09:59 1998 Ross Johnson <rpj@ixobrychus.canberra.edu.au>
* sync.c: Rename all instances of _pthread_count_mutex to _pthread_table_mutex. * implement.h: Rename _pthread_count_mutex to _pthread_table_mutex. * global.c: Rename _pthread_count_mutex to _pthread_table_mutex. * create.c (pthread_create): Add critical sections. (_pthread_start_call): Rename _pthread_count_mutex to _pthread_table_mutex.
Diffstat (limited to 'sync.c')
-rw-r--r--sync.c12
1 files changed, 6 insertions, 6 deletions
diff --git a/sync.c b/sync.c
index 721574e..7483598 100644
--- a/sync.c
+++ b/sync.c
@@ -76,7 +76,7 @@ pthread_join(pthread_t thread, void ** valueptr)
target_thread_mutex = _PTHREAD_THREAD_MUTEX(target);
/* CRITICAL SECTION */
- pthread_mutex_lock(&_pthread_count_mutex);
+ pthread_mutex_lock(&_pthread_table_mutex);
/* If the thread is in DETACHED state, then join will return
immediately. */
@@ -89,7 +89,7 @@ pthread_join(pthread_t thread, void ** valueptr)
target->join_count++;
- pthread_mutex_lock(&_pthread_count_mutex);
+ pthread_mutex_lock(&_pthread_table_mutex);
/* END CRITICAL SECTION */
/* CANCELATION POINT */
@@ -116,7 +116,7 @@ pthread_join(pthread_t thread, void ** valueptr)
following critical section. */
/* CRITICAL SECTION */
- pthread_mutex_lock(&_pthread_count_mutex);
+ pthread_mutex_lock(&_pthread_table_mutex);
/* Collect the value pointer passed to pthread_exit(). If
another thread detaches our target thread while we're
@@ -144,7 +144,7 @@ pthread_join(pthread_t thread, void ** valueptr)
_pthread_delete_thread_entry(target);
}
- pthread_mutex_lock(&_pthread_count_mutex);
+ pthread_mutex_lock(&_pthread_table_mutex);
/* END CRITICAL SECTION */
return ret;
@@ -163,7 +163,7 @@ pthread_detach(pthread_t thread)
pthread_mutex_t * target_thread_mutex;
/* CRITICAL SECTION */
- pthread_mutex_lock(&_pthread_count_mutex);
+ pthread_mutex_lock(&_pthread_table_mutex);
target = _pthread_find_thread_entry(thread);
@@ -195,7 +195,7 @@ pthread_detach(pthread_t thread)
}
}
- pthread_mutex_unlock(&_pthread_count_mutex);
+ pthread_mutex_unlock(&_pthread_table_mutex);
/* END CRITICAL SECTION */
return ret;