mirror of
https://github.com/asterisk/asterisk.git
synced 2025-10-12 15:45:18 +00:00
Add some debugging code that ensures that when we do deadlock avoidance, we
don't lose the information about how a lock was originally acquired. git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@118953 65c4cc65-6c06-0410-ace0-fbb531ad65f3
This commit is contained in:
@@ -574,9 +574,7 @@ static void mgcp_queue_frame(struct mgcp_subchannel *sub, struct ast_frame *f)
|
||||
ast_mutex_unlock(&sub->owner->lock);
|
||||
break;
|
||||
} else {
|
||||
ast_mutex_unlock(&sub->lock);
|
||||
usleep(1);
|
||||
ast_mutex_lock(&sub->lock);
|
||||
DEADLOCK_AVOIDANCE(&sub->lock);
|
||||
}
|
||||
} else
|
||||
break;
|
||||
@@ -592,9 +590,7 @@ static void mgcp_queue_hangup(struct mgcp_subchannel *sub)
|
||||
ast_mutex_unlock(&sub->owner->lock);
|
||||
break;
|
||||
} else {
|
||||
ast_mutex_unlock(&sub->lock);
|
||||
usleep(1);
|
||||
ast_mutex_lock(&sub->lock);
|
||||
DEADLOCK_AVOIDANCE(&sub->lock);
|
||||
}
|
||||
} else
|
||||
break;
|
||||
|
Reference in New Issue
Block a user