]> git.ipfire.org Git - thirdparty/asterisk.git/commit
Fix some potential deadlocks pointed out by helgrind.
authorRichard Mudgett <rmudgett@digium.com>
Tue, 11 Oct 2011 19:26:18 +0000 (19:26 +0000)
committerRichard Mudgett <rmudgett@digium.com>
Tue, 11 Oct 2011 19:26:18 +0000 (19:26 +0000)
commitbaa5ff86e52e918f9318ff47ef0e9af053cf655e
tree9edbc5d7c7c1bafde7b87541c83ed6a850e65f87
parent4348fc2cc90284fb037dfb512bb2cc442e5dd9ef
Fix some potential deadlocks pointed out by helgrind.

* Fixed deadlock potential calling dialog_unlink_all() in
__sip_autodestruct().  Found by helgrind.

* Fixed deadlock potential in handle_request_invite() after calling
sip_new().  Found by helgrind.

* The sip_new() function now returns with the created channel already
locked.

* Removed the dead code that starts a PBX in in sip_new().  No sip_new()
callers caused that code to be executed and it was a bad thing to do
anyway.

* Removed unused parameters and return value from dialog_unlink_all().

* Made dialog_unlink_all() and __sip_autodestruct() safely obtain the
owner and private channel locks without a deadlock avoidance loop.
........

Merged revisions 340284 from http://svn.asterisk.org/svn/asterisk/branches/1.8

git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/10@340310 65c4cc65-6c06-0410-ace0-fbb531ad65f3
channels/chan_sip.c
channels/sip/include/dialog.h