rwlock: Don't use buggy pthread_rwlock on OS X

Recursive read locks don't seem to work properly, at least on 10.9.
This commit is contained in:
Martin Willi
2013-10-24 14:53:47 +02:00
parent 2077d996a9
commit 181d071363
+7
View File
@@ -27,6 +27,13 @@
#include "mutex.h"
#include "lock_profiler.h"
#ifdef __APPLE__
/* while pthread_rwlock_rdlock(3) says that it supports multiple read locks,
* this does not seem to be true. After releasing the a recursive rdlock,
* a subsequent wrlock fails... */
# undef HAVE_PTHREAD_RWLOCK_INIT
#endif
typedef struct private_rwlock_t private_rwlock_t;
typedef struct private_rwlock_condvar_t private_rwlock_condvar_t;