[asterisk-commits] mmichelson: trunk r148913 - in /trunk: ./ channels/chan_local.c

SVN commits to the Asterisk project asterisk-commits at lists.digium.com
Tue Oct 14 12:38:07 CDT 2008


Author: mmichelson
Date: Tue Oct 14 12:38:06 2008
New Revision: 148913

URL: http://svn.digium.com/view/asterisk?view=rev&rev=148913
Log:
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


........

Modified:
    trunk/   (props changed)
    trunk/channels/chan_local.c

Propchange: trunk/
------------------------------------------------------------------------------
Binary property 'branch-1.4-merged' - no diff available.

Modified: trunk/channels/chan_local.c
URL: http://svn.digium.com/view/asterisk/trunk/channels/chan_local.c?view=diff&rev=148913&r1=148912&r2=148913
==============================================================================
--- trunk/channels/chan_local.c (original)
+++ trunk/channels/chan_local.c Tue Oct 14 12:38:06 2008
@@ -584,8 +584,12 @@
 	} 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);
 		}
 	}
 	




More information about the asterisk-commits mailing list