From b77a92d5dbb0147c8dd872c0be8f4fe73a750490 Mon Sep 17 00:00:00 2001 From: rpj Date: Tue, 5 Jun 2001 07:48:19 +0000 Subject: * nonportable.c (pthread_mutex_setdefaultkind_np): Remove - should not have been included in the first place. (pthread_mutex_getdefaultkind_np): Likewise. * global.c (ptw32_mutex_default_kind): Likewise. * mutex.c (pthread_mutex_init): Remove use of ptw32_mutex_default_kind. * pthread.h (pthread_mutex_setdefaultkind_np): Likewise. (pthread_mutex_getdefaultkind_np): Likewise. * pthread.def (pthread_mutexattr_setkind_np): Added. (pthread_mutexattr_getkind_np): Likewise. * README: Many changes that should have gone in before the last snapshot. * README.NONPORTABLE: New - referred to by ANNOUNCE but never created; documents the non-portable routines included in the library - moved from README with new routines added. * ANNOUNCE (pthread_mutexattr_setkind_np): Added to compliance list. (pthread_mutexattr_getkind_np): Likewise. --- mutex.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'mutex.c') diff --git a/mutex.c b/mutex.c index 086c0bc..5e01536 100644 --- a/mutex.c +++ b/mutex.c @@ -130,7 +130,9 @@ pthread_mutex_init(pthread_mutex_t *mutex, const pthread_mutexattr_t *attr) mx->lock_idx = PTW32_MUTEX_LOCK_IDX_INIT; mx->recursive_count = 0; - mx->kind = attr == NULL || *attr == NULL ? ptw32_mutex_default_kind : (*attr)->kind; + mx->kind = (attr == NULL || *attr == NULL + ? PTHREAD_MUTEX_DEFAULT + : (*attr)->kind); mx->ownerThread = NULL; InitializeCriticalSection( &mx->try_lock_cs ); mx->wait_sema = CreateSemaphore( NULL, 0, 1, NULL ); -- cgit v1.2.3