Index: include/asterisk/lock.h =================================================================== --- include/asterisk/lock.h (revision 84889) +++ include/asterisk/lock.h (working copy) @@ -165,6 +165,7 @@ const char *mutex_name, ast_mutex_t *t, pthread_mutexattr_t *attr) { + int i; #ifdef AST_MUTEX_INIT_W_CONSTRUCTORS int canlog = strcmp(filename, "logger.c"); @@ -180,10 +181,12 @@ } #endif - t->file[0] = filename; - t->lineno[0] = lineno; - t->func[0] = func; - t->thread[0] = 0; + for (i = 0; i < AST_MAX_REENTRANCY; i++) { + t->file[i] = NULL; + t->lineno[i] = 0; + t->func[i] = NULL; + t->thread[i] = 0; + } t->reentrancy = 0; t->track = track;