diff options
author | markster <markster@f38db490-d61c-443f-a65b-d21fe96a405b> | 2004-05-24 15:28:36 +0000 |
---|---|---|
committer | markster <markster@f38db490-d61c-443f-a65b-d21fe96a405b> | 2004-05-24 15:28:36 +0000 |
commit | b5fe357533576f9e70ac0ac553b8efe90520ea48 (patch) | |
tree | 70348639dc2eec6c4b47582ebfe7558dfc2b48d6 /include/asterisk/lock.h | |
parent | bb92b0b9b210ee937a498970963d871e9ea6f0dc (diff) |
Fix potential segfault, add support for MacOS X locks
git-svn-id: http://svn.digium.com/svn/asterisk/trunk@3058 f38db490-d61c-443f-a65b-d21fe96a405b
Diffstat (limited to 'include/asterisk/lock.h')
-rwxr-xr-x | include/asterisk/lock.h | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/include/asterisk/lock.h b/include/asterisk/lock.h index 72743c04f..c40a1ddcf 100755 --- a/include/asterisk/lock.h +++ b/include/asterisk/lock.h @@ -20,6 +20,14 @@ #define AST_PTHREADT_NULL (pthread_t) -1 #define AST_PTHREADT_STOP (pthread_t) -2 +#ifdef __APPLE__ +/* Provide the Linux initializers for MacOS X */ +#define PTHREAD_MUTEX_RECURSIVE_NP PTHREAD_MUTEX_RECURSIVE +#define PTHREAD_RECURSIVE_MUTEX_INITIALIZER_NP { 0x4d555458, \ + { 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, \ + 0x20 } } +#endif + #ifdef DEBUG_THREADS #ifdef THREAD_CRASH |