[asterisk-commits] tilghman: trunk r255796 - /trunk/include/asterisk/lock.h

SVN commits to the Asterisk project asterisk-commits at lists.digium.com
Thu Apr 1 13:16:42 CDT 2010


Author: tilghman
Date: Thu Apr  1 13:16:37 2010
New Revision: 255796

URL: http://svnview.digium.com/svn/asterisk?view=rev&rev=255796
Log:
Fix DEBUG_THREADS build on Darwin.

(closes issue #16828)
 Reported by: oej
 Patches: 
       20100331__issue16828.diff.txt uploaded by tilghman (license 14)

Modified:
    trunk/include/asterisk/lock.h

Modified: trunk/include/asterisk/lock.h
URL: http://svnview.digium.com/svn/asterisk/trunk/include/asterisk/lock.h?view=diff&rev=255796&r1=255795&r2=255796
==============================================================================
--- trunk/include/asterisk/lock.h (original)
+++ trunk/include/asterisk/lock.h Thu Apr  1 13:16:37 2010
@@ -83,7 +83,7 @@
 #define AST_PTHREADT_NULL (pthread_t) -1
 #define AST_PTHREADT_STOP (pthread_t) -2
 
-#if defined(SOLARIS) || defined(BSD)
+#if (defined(SOLARIS) || defined(BSD)) && !defined(__Darwin__)
 #define AST_MUTEX_INIT_W_CONSTRUCTORS
 #endif /* SOLARIS || BSD */
 
@@ -460,10 +460,6 @@
 		__ast_mutex_logger("%s line %d (%s): Error destroying mutex %s: %s\n",
 				   filename, lineno, func, mutex_name, strerror(res));
 	}
-#ifndef PTHREAD_RECURSIVE_MUTEX_INITIALIZER_NP
-	else
-		t->mutex = PTHREAD_MUTEX_INIT_VALUE;
-#endif
 	ast_reentrancy_lock(lt);
 	lt->file[0] = filename;
 	lt->lineno[0] = lineno;




More information about the asterisk-commits mailing list