[Asterisk-code-review] chan iax2: Prevent deadlock between hangup and sending lagrq... (asterisk[master])
Y Ateya
asteriskteam at digium.com
Thu May 7 06:42:17 CDT 2015
Y Ateya has posted comments on this change.
Change subject: chan_iax2: Prevent deadlock between hangup and sending lagrq/ping
......................................................................
Patch Set 6:
(2 comments)
https://gerrit.asterisk.org/#/c/169/6/channels/chan_iax2.c
File channels/chan_iax2.c:
Line 2071:
:
:
:
:
> A recent fix in the scheduler made AST_SCHED_DEL_SPINLOCK() no longer work
This is exactly was my first solution (Patch 1); but it created deadlocks while testing it. Kindly check http://lists.digium.com/pipermail/asterisk-dev/2015-April/074855.html.
In some cases, iax2_destroy_helper is called while the mutex is locked twice.
I didn't like AST_SCHED_DEL_SPINLOCK anyways!
Line 1688: if (!iaxs[callno] || (iaxs[callno] && iaxs[callno]->destroy_initiated)) {
> You cannot access the contents of iaxs[] without holding the iaxsl[] lock.
This is a good point.
--
To view, visit https://gerrit.asterisk.org/169
To unsubscribe, visit https://gerrit.asterisk.org/settings
Gerrit-MessageType: comment
Gerrit-Change-Id: I03bec1fc8faacb89630269e935fa667c6d6c080c
Gerrit-PatchSet: 6
Gerrit-Project: asterisk
Gerrit-Branch: master
Gerrit-Owner: Y Ateya <y.ateya at starkbits.com>
Gerrit-Reviewer: George Joseph <george.joseph at fairview5.com>
Gerrit-Reviewer: Joshua Colp <jcolp at digium.com>
Gerrit-Reviewer: Matt Jordan <mjordan at digium.com>
Gerrit-Reviewer: Richard Mudgett <rmudgett at digium.com>
Gerrit-Reviewer: Y Ateya <y.ateya at starkbits.com>
Gerrit-HasComments: Yes
More information about the asterisk-code-review
mailing list