aboutsummaryrefslogtreecommitdiffstats
path: root/include/asterisk
diff options
context:
space:
mode:
authorrussell <russell@f38db490-d61c-443f-a65b-d21fe96a405b>2007-12-07 21:17:24 +0000
committerrussell <russell@f38db490-d61c-443f-a65b-d21fe96a405b>2007-12-07 21:17:24 +0000
commitc1b7184750e8f117e1c5e65faacb15be03510a52 (patch)
tree44f74c570d6ffd903c95e1b6b110b502322b6260 /include/asterisk
parent0d4f49f97e38b2755cd1fb63f5e81093d8fa6c45 (diff)
Fix another bug in the DEBUG_THREADS code. The ast_mutex_init() function had
the mutex attribute object marked as static. This means that multiple threads initializing locks at the same time could step on each other and end up with improperly initialized locks. (found when tracking down locking issues related to issue #11080) git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.4@91828 f38db490-d61c-443f-a65b-d21fe96a405b
Diffstat (limited to 'include/asterisk')
-rw-r--r--include/asterisk/lock.h2
1 files changed, 1 insertions, 1 deletions
diff --git a/include/asterisk/lock.h b/include/asterisk/lock.h
index 629239843..16ff071cb 100644
--- a/include/asterisk/lock.h
+++ b/include/asterisk/lock.h
@@ -206,7 +206,7 @@ static inline int __ast_pthread_mutex_init(int track, const char *filename, int
const char *mutex_name, ast_mutex_t *t)
{
int res;
- static pthread_mutexattr_t attr;
+ pthread_mutexattr_t attr;
#ifdef AST_MUTEX_INIT_W_CONSTRUCTORS