(closes issue #15525)
Reported by: elguero
Patches:
iax2-double-unlock.patch uploaded by elguero (license 37)
15525.diff uploaded by dvossel (license 671)
Tested by: dvossel
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@207225
65c4cc65-6c06-0410-ace0-
fbb531ad65f3
do {
if (ast_channel_trylock(iaxs[callno]->owner)) {
DEADLOCK_AVOIDANCE(&iaxsl[callno]);
- }
- else {
+ } else {
locked = 1;
owner = iaxs[callno]->owner;
}
}
ast_set_hangupsource(iaxs[callno]->owner, iaxs[callno]->owner->name, 0);
ast_channel_unlock(owner);
- }
- if (locked) {
+ } else if(locked) {
ast_channel_unlock(owner);
}
}
-
static int socket_process(struct iax2_thread *thread)
{
struct sockaddr_in sin;