[Asterisk-code-review] sip/dialplan functions.c: Fix /channels/chan sip/test sip rt... (asterisk[master])

Richard Mudgett asteriskteam at digium.com
Wed Mar 16 14:55:13 CDT 2016


Hello Anonymous Coward #1000019, George Joseph, Corey Farrell,

I'd like you to reexamine a change.  Please visit

    https://gerrit.asterisk.org/2405

to look at the new patch set (#2).

Change subject: sip/dialplan_functions.c: Fix /channels/chan_sip/test_sip_rtpqos crash.
......................................................................

sip/dialplan_functions.c: Fix /channels/chan_sip/test_sip_rtpqos crash.

This patch is part of a series to resolve deadlocks in chan_sip.c.

Delaying destruction of the chan_sip sip_pvt structures caused the
/channels/chan_sip/test_sip_rtpqos unit test to crash.  That test
registers a special test ast_rtp_engine with the rtp engine module.  When
the unit test completes it cleans up by unregistering the test
ast_rtp_engine and exits.  Since the delayed destruction of the sip_pvt
happens after the unit test returns, the destructor tries to call the rtp
engine destroy callback of the test ast_rtp_engine auto variable which no
longer exists on the stack.

* Change the test ast_rtp_engine auto variable to a static variable.  Now
the variable can still exist after the unit test exits so the delayed
sip_pvt destruction can complete successfully.

ASTERISK-25023

Change-Id: I61e34a12d425189ef7e96fc69ae14993f82f3f13
---
M channels/sip/dialplan_functions.c
1 file changed, 1 insertion(+), 1 deletion(-)


  git pull ssh://gerrit.asterisk.org:29418/asterisk refs/changes/05/2405/2
-- 
To view, visit https://gerrit.asterisk.org/2405
To unsubscribe, visit https://gerrit.asterisk.org/settings

Gerrit-MessageType: newpatchset
Gerrit-Change-Id: I61e34a12d425189ef7e96fc69ae14993f82f3f13
Gerrit-PatchSet: 2
Gerrit-Project: asterisk
Gerrit-Branch: master
Gerrit-Owner: Richard Mudgett <rmudgett at digium.com>
Gerrit-Reviewer: Anonymous Coward #1000019
Gerrit-Reviewer: Corey Farrell <git at cfware.com>
Gerrit-Reviewer: George Joseph <george.joseph at fairview5.com>
Gerrit-Reviewer: Joshua Colp <jcolp at digium.com>
Gerrit-Reviewer: Richard Mudgett <rmudgett at digium.com>



More information about the asterisk-code-review mailing list