[prev in list] [next in list] [prev in thread] [next in thread]
List: asterisk-commits
Subject: [asterisk-commits] kmoore: branch 12 r414948 - /branches/12/res/res_pjsip_refer.c
From: SVN commits to the Asterisk project <asterisk-commits () lists ! digium ! com>
Date: 2014-05-30 14:46:38
Message-ID: mailman.1182.1401461182.1075.asterisk-commits () lists ! digium ! com
[Download RAW message or body]
Author: kmoore
Date: Fri May 30 09:46:32 2014
New Revision: 414948
URL: http://svnview.digium.com/svn/asterisk?view=rev&rev=414948
Log:
PJSIP: Prevent crash on blind transfer
Blind transfers don't go too well with NULL channels which can occur if
the channel has already been transferred away.
(closes issue ASTERISK-23718)
Reported by: Jonathan Rose
Modified:
branches/12/res/res_pjsip_refer.c
Modified: branches/12/res/res_pjsip_refer.c
URL: http://svnview.digium.com/svn/asterisk/branches/12/res/res_pjsip_refer.c?view=diff&rev=414948&r1=414947&r2=414948
==============================================================================
--- branches/12/res/res_pjsip_refer.c (original)
+++ branches/12/res/res_pjsip_refer.c Fri May 30 09:46:32 2014
@@ -692,11 +692,16 @@
static int refer_incoming_blind_request(struct ast_sip_session *session, \
pjsip_rx_data *rdata, pjsip_sip_uri *target, struct refer_progress *progress)
{
- const char *context = (session->channel ? \
pbx_builtin_getvar_helper(session->channel, "TRANSFER_CONTEXT") : ""); + const char \
*context; char exten[AST_MAX_EXTENSION];
struct refer_blind refer = { 0, };
+ if (!session->channel) {
+ return 404;
+ }
+
/* If no explicit transfer context has been provided use their configured context \
*/ + context = pbx_builtin_getvar_helper(session->channel, "TRANSFER_CONTEXT");
if (ast_strlen_zero(context)) {
context = session->endpoint->context;
}
--
_____________________________________________________________________
-- Bandwidth and Colocation Provided by http://www.api-digital.com --
asterisk-commits mailing list
To UNSUBSCRIBE or update options visit:
http://lists.digium.com/mailman/listinfo/asterisk-commits
[prev in list] [next in list] [prev in thread] [next in thread]
Configure |
About |
News |
Add a list |
Sponsored by KoreLogic