Review Board 1.7.16


Locking issue in action_bridge and bridge_exec

Review Request #167 - Created Feb. 17, 2009 and submitted

David Vossel
/trunk
0014296
Reviewers
asterisk-dev
russell
Asterisk
action_bridge() and bridge_exec() both search for the channels to bridge to, and then immediately drop the lock.  Instead, they should hold the lock until the masquerade is complete.  This will guarantee the channel remains and prevent any other weirdness from occurring.  In action_bridge() some more weirdness comes into play.  Both channels are needlessly locked at the same time and perform the exact same logic.  It makes sense from a coding organizational standpoint, but could cause a theoretical deadlock so I split the code up.  There is an issue associated with this, but since its a rather complicated thing to reproduce I'm not certain this allone will close it.
I've executed both functions with no problems. 
Review request changed
Updated (Feb. 18, 2009, 9:16 a.m.)
fixed russell's comments. 
Ship it!
Posted (Feb. 18, 2009, 9:47 a.m.)
Other than these couple of little things, this looks good to go.

Nice work!
/trunk/main/features.c (Diff revision 2)
 
 
 
Trim the trailing whitespace
/trunk/main/features.c (Diff revision 2)
 
 
 
 
 
 
 
You need to do an ast_hangup() of tmpchana here

https://reviewboard.asterisk.org/ runs on a server provided by Digium, Inc. and uses bandwidth donated to the open source Asterisk community by API Digital Communications in Huntsville, AL USA.
Please report problems with this site to asteriskteam@digium.com.