Merged revisions 310781 via svnmerge from
https://origsvn.digium.com/svn/asterisk/branches/1.8 ........ r310781 | alecdavis | 2011-03-15 14:00:55 +1300 (Tue, 15 Mar 2011) | 10 lines core show locks: display ThreadID in hexadecimal Allow easier cross referencing of thread ID's with GDB backtraces (closes issue #18968) Reported by: alecdavis Patches: bug18968.diff.txt uploaded by alecdavis (license 585) ........ git-svn-id: http://svn.digium.com/svn/asterisk/trunk@310833 f38db490-d61c-443f-a65b-d21fe96a405b
This commit is contained in:
parent
bf0bc7d7a7
commit
b1223595f4
|
@ -915,7 +915,7 @@ static char *handle_show_locks(struct ast_cli_entry *e, int cmd, struct ast_cli_
|
||||||
AST_LIST_TRAVERSE(&lock_infos, lock_info, entry) {
|
AST_LIST_TRAVERSE(&lock_infos, lock_info, entry) {
|
||||||
int i;
|
int i;
|
||||||
if (lock_info->num_locks) {
|
if (lock_info->num_locks) {
|
||||||
ast_str_append(&str, 0, "=== Thread ID: %ld (%s)\n", (long) lock_info->thread_id,
|
ast_str_append(&str, 0, "=== Thread ID: 0x%lx (%s)\n", (long) lock_info->thread_id,
|
||||||
lock_info->thread_name);
|
lock_info->thread_name);
|
||||||
pthread_mutex_lock(&lock_info->lock);
|
pthread_mutex_lock(&lock_info->lock);
|
||||||
for (i = 0; str && i < lock_info->num_locks; i++) {
|
for (i = 0; str && i < lock_info->num_locks; i++) {
|
||||||
|
|
Reference in New Issue