#ifdef DEBUG_THREADS
struct ast_lock_track *lt = NULL;
int canlog = t->tracking && strcmp(filename, "logger.c");
-#ifdef HAVE_BKTR
struct ast_bt *bt = NULL;
-#endif
if (t->tracking) {
lt = ast_get_reentrancy(&t->track);
bt = <->backtrace[lt->reentrancy];
}
ast_reentrancy_unlock(lt);
-
- ast_store_lock_info(AST_MUTEX, filename, lineno, func, mutex_name, t, bt);
-#else
- ast_store_lock_info(AST_MUTEX, filename, lineno, func, mutex_name, t);
#endif
+ ast_store_lock_info(AST_MUTEX, filename, lineno, func, mutex_name, t, bt);
}
#endif /* DEBUG_THREADS */
} else {
bt = NULL;
}
- ast_remove_lock_info(t, bt);
-#else
- ast_remove_lock_info(t);
#endif
+ ast_remove_lock_info(t, bt);
}
if (res) {
__ast_mutex_logger("%s line %d (%s): Error obtaining mutex: %s\n",
#ifdef DEBUG_THREADS
struct ast_lock_track *lt = NULL;
int canlog = t->tracking && strcmp(filename, "logger.c");
-#ifdef HAVE_BKTR
struct ast_bt *bt = NULL;
-#endif
if (t->tracking) {
lt = ast_get_reentrancy(&t->track);
bt = <->backtrace[lt->reentrancy];
}
ast_reentrancy_unlock(lt);
-
- ast_store_lock_info(AST_MUTEX, filename, lineno, func, mutex_name, t, bt);
-#else
- ast_store_lock_info(AST_MUTEX, filename, lineno, func, mutex_name, t);
#endif
+ ast_store_lock_info(AST_MUTEX, filename, lineno, func, mutex_name, t, bt);
}
#endif /* DEBUG_THREADS */
#ifdef DEBUG_THREADS
struct ast_lock_track *lt = NULL;
int canlog = t->tracking && strcmp(filename, "logger.c");
-#ifdef HAVE_BKTR
struct ast_bt *bt = NULL;
-#endif
#if defined(AST_MUTEX_INIT_W_CONSTRUCTORS) && defined(CAN_COMPARE_MUTEX_TO_INIT_VALUE)
if ((t->mutex) == ((pthread_mutex_t) PTHREAD_MUTEX_INITIALIZER)) {
#endif
ast_reentrancy_unlock(lt);
-#ifdef HAVE_BKTR
ast_remove_lock_info(t, bt);
-#else
- ast_remove_lock_info(t);
-#endif
}
#endif /* DEBUG_THREADS */
#ifdef DEBUG_THREADS
struct ast_lock_track *lt = NULL;
int canlog = t->tracking && strcmp(filename, "logger.c");
-#ifdef HAVE_BKTR
struct ast_bt *bt = NULL;
-#endif
int lock_found = 0;
#if defined(AST_MUTEX_INIT_W_CONSTRUCTORS) && defined(CAN_COMPARE_MUTEX_TO_INIT_VALUE)
ast_reentrancy_unlock(lt);
-#ifdef HAVE_BKTR
ast_remove_lock_info(t, bt);
-#else
- ast_remove_lock_info(t);
-#endif
}
#endif /* DEBUG_THREADS */
#ifdef DEBUG_THREADS
struct ast_lock_track *lt = NULL;
int canlog = t->tracking && strcmp(filename, "logger.c");
-#ifdef HAVE_BKTR
struct ast_bt *bt = NULL;
-#endif
if (t->tracking) {
lt = ast_get_reentrancy(&t->track);
bt = <->backtrace[lt->reentrancy];
}
ast_reentrancy_unlock(lt);
-
- ast_store_lock_info(AST_RDLOCK, filename, line, func, name, t, bt);
-#else
- ast_store_lock_info(AST_RDLOCK, filename, line, func, name, t);
#endif
+ ast_store_lock_info(AST_RDLOCK, filename, line, func, name, t, bt);
}
#endif /* DEBUG_THREADS */
} else {
bt = NULL;
}
- ast_remove_lock_info(t, bt);
-#else
- ast_remove_lock_info(t);
#endif
+ ast_remove_lock_info(t, bt);
}
if (res) {
#ifdef DEBUG_THREADS
struct ast_lock_track *lt = NULL;
int canlog = t->tracking && strcmp(filename, "logger.c");
-#ifdef HAVE_BKTR
struct ast_bt *bt = NULL;
-#endif
if (t->tracking) {
lt = ast_get_reentrancy(&t->track);
bt = <->backtrace[lt->reentrancy];
}
ast_reentrancy_unlock(lt);
-
- ast_store_lock_info(AST_WRLOCK, filename, line, func, name, t, bt);
-#else
- ast_store_lock_info(AST_WRLOCK, filename, line, func, name, t);
#endif
+ ast_store_lock_info(AST_WRLOCK, filename, line, func, name, t, bt);
}
#endif /* DEBUG_THREADS */
} else {
bt = NULL;
}
- ast_remove_lock_info(t, bt);
-#else
- ast_remove_lock_info(t);
#endif
+ ast_remove_lock_info(t, bt);
}
if (res) {
__ast_mutex_logger("%s line %d (%s): Error obtaining write lock: %s\n",
#ifdef DEBUG_THREADS
struct ast_lock_track *lt = NULL;
int canlog = t->tracking && strcmp(filename, "logger.c");
-#ifdef HAVE_BKTR
struct ast_bt *bt = NULL;
-#endif
if (t->tracking) {
lt = ast_get_reentrancy(&t->track);
bt = <->backtrace[lt->reentrancy];
}
ast_reentrancy_unlock(lt);
-
- ast_store_lock_info(AST_WRLOCK, filename, line, func, name, t, bt);
-#else
- ast_store_lock_info(AST_WRLOCK, filename, line, func, name, t);
#endif
+ ast_store_lock_info(AST_WRLOCK, filename, line, func, name, t, bt);
}
#endif /* DEBUG_THREADS */
} else {
bt = NULL;
}
- ast_remove_lock_info(t, bt);
-#else
- ast_remove_lock_info(t);
#endif
+ ast_remove_lock_info(t, bt);
}
if (res) {
__ast_mutex_logger("%s line %d (%s): Error obtaining read lock: %s\n",
#ifdef DEBUG_THREADS
struct ast_lock_track *lt = NULL;
int canlog = t->tracking && strcmp(filename, "logger.c");
-#ifdef HAVE_BKTR
struct ast_bt *bt = NULL;
-#endif
if (t->tracking) {
lt = ast_get_reentrancy(&t->track);
bt = <->backtrace[lt->reentrancy];
}
ast_reentrancy_unlock(lt);
-
- ast_store_lock_info(AST_WRLOCK, filename, line, func, name, t, bt);
-#else
- ast_store_lock_info(AST_WRLOCK, filename, line, func, name, t);
#endif
+ ast_store_lock_info(AST_WRLOCK, filename, line, func, name, t, bt);
}
#endif /* DEBUG_THREADS */
} else {
bt = NULL;
}
- ast_remove_lock_info(t, bt);
-#else
- ast_remove_lock_info(t);
#endif
+ ast_remove_lock_info(t, bt);
}
if (res) {
__ast_mutex_logger("%s line %d (%s): Error obtaining read lock: %s\n",
#ifdef DEBUG_THREADS
struct ast_lock_track *lt = NULL;
-#ifdef HAVE_BKTR
struct ast_bt *bt = NULL;
-#endif
if (t->tracking) {
lt = ast_get_reentrancy(&t->track);
bt = <->backtrace[lt->reentrancy];
}
ast_reentrancy_unlock(lt);
-
- ast_store_lock_info(AST_RDLOCK, filename, line, func, name, t, bt);
-#else
- ast_store_lock_info(AST_RDLOCK, filename, line, func, name, t);
#endif
+ ast_store_lock_info(AST_RDLOCK, filename, line, func, name, t, bt);
}
#endif /* DEBUG_THREADS */
#ifdef DEBUG_THREADS
struct ast_lock_track *lt = NULL;
-#ifdef HAVE_BKTR
struct ast_bt *bt = NULL;
-#endif
if (t->tracking) {
lt = ast_get_reentrancy(&t->track);
bt = <->backtrace[lt->reentrancy];
}
ast_reentrancy_unlock(lt);
-
- ast_store_lock_info(AST_WRLOCK, filename, line, func, name, t, bt);
-#else
- ast_store_lock_info(AST_WRLOCK, filename, line, func, name, t);
#endif
+ ast_store_lock_info(AST_WRLOCK, filename, line, func, name, t, bt);
}
#endif /* DEBUG_THREADS */