From: alecdavis Date: Tue, 21 Aug 2018 23:45:33 +0000 (+1200) Subject: chan_sip: remove unnecessary ast_channel_unlock(peer) as RAII looks after it X-Git-Tag: 15.6.0-rc1~5^2 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=de40ba0e02649c4034b1e6012a86dc439b7abc16;p=thirdparty%2Fasterisk.git chan_sip: remove unnecessary ast_channel_unlock(peer) as RAII looks after it Otherwise console output (get_refer_info): mutex 'peer' freed more times than we've locked! (get_refer_info): Error releasing mutex: Operation not permitted or (get_refer_info): attempted unlock mutex 'peer' without owning it! (__ast_read): 'peer' was locked here. ...dump_backtrace (get_refer_info): Error releasing mutex: Operation not permitted (__ast_read): mutex 'chan' freed more times than we've locked! ASTERISK-28011 #close Change-Id: I6e45f2764ba4f3273a943300f91ac9b461ac2893 --- diff --git a/channels/chan_sip.c b/channels/chan_sip.c index ad064220b7..de61343571 100644 --- a/channels/chan_sip.c +++ b/channels/chan_sip.c @@ -18740,7 +18740,6 @@ static int get_refer_info(struct sip_pvt *transferer, struct sip_request *outgoi S_OR(transferer->context, NULL)); pbx_builtin_setvar_helper(peer, "__SIPREFERREDBYHDR", S_OR(p_referred_by, NULL)); - ast_channel_unlock(peer); } owner_relock = sip_pvt_lock_full(transferer);