Fix heim_threads.h rwlocks macros for pthreads
This commit is contained in:
@@ -92,8 +92,8 @@
|
|||||||
#define HEIMDAL_MUTEX_unlock(m) pthread_mutex_unlock(m)
|
#define HEIMDAL_MUTEX_unlock(m) pthread_mutex_unlock(m)
|
||||||
#define HEIMDAL_MUTEX_destroy(m) pthread_mutex_destroy(m)
|
#define HEIMDAL_MUTEX_destroy(m) pthread_mutex_destroy(m)
|
||||||
|
|
||||||
#define HEIMDAL_RWLOCK rwlock_t
|
#define HEIMDAL_RWLOCK pthread_rwlock_t
|
||||||
#define HEIMDAL_RWLOCK_INITIALIZER RWLOCK_INITIALIZER
|
#define HEIMDAL_RWLOCK_INITIALIZER PTHREAD_RWLOCK_INITIALIZER
|
||||||
#define HEIMDAL_RWLOCK_init(l) pthread_rwlock_init(l, NULL)
|
#define HEIMDAL_RWLOCK_init(l) pthread_rwlock_init(l, NULL)
|
||||||
#define HEIMDAL_RWLOCK_rdlock(l) pthread_rwlock_rdlock(l)
|
#define HEIMDAL_RWLOCK_rdlock(l) pthread_rwlock_rdlock(l)
|
||||||
#define HEIMDAL_RWLOCK_wrlock(l) pthread_rwlock_wrlock(l)
|
#define HEIMDAL_RWLOCK_wrlock(l) pthread_rwlock_wrlock(l)
|
||||||
@@ -215,7 +215,7 @@ heim_rwlock_trywrlock(heim_rwlock_t *l)
|
|||||||
return EBUSY;
|
return EBUSY;
|
||||||
}
|
}
|
||||||
|
|
||||||
static inline vint
|
static inline int
|
||||||
heim_rwlock_unlock(heim_rwlock_t *l)
|
heim_rwlock_unlock(heim_rwlock_t *l)
|
||||||
{
|
{
|
||||||
if (l->exclusive) {
|
if (l->exclusive) {
|
||||||
|
Reference in New Issue
Block a user