dect
/
asterisk
Archived
13
0
Fork 0

Merged revisions 148912 via svnmerge from

https://origsvn.digium.com/svn/asterisk/branches/1.4

........
r148912 | mmichelson | 2008-10-14 12:33:38 -0500 (Tue, 14 Oct 2008) | 9 lines

Deadlock prevention in chan_local.

(closes issue #13676)
Reported by: tacvbo
Patches:
      13676.patch uploaded by putnopvut (license 60)
Tested by: tacvbo


........


git-svn-id: http://svn.digium.com/svn/asterisk/trunk@148913 f38db490-d61c-443f-a65b-d21fe96a405b
This commit is contained in:
mmichelson 2008-10-14 17:38:06 +00:00
parent 420a6cb303
commit 234f067c8c
1 changed files with 4 additions and 0 deletions

View File

@ -584,8 +584,12 @@ static int local_hangup(struct ast_channel *ast)
} else {
p->owner = NULL;
ast_module_user_remove(p->u_owner);
while (p->chan && ast_channel_trylock(p->chan)) {
DEADLOCK_AVOIDANCE(&p->lock);
}
if (p->chan) {
ast_queue_hangup(p->chan);
ast_channel_unlock(p->chan);
}
}