aboutsummaryrefslogtreecommitdiffstats
path: root/channels
diff options
context:
space:
mode:
authormnicholson <mnicholson@f38db490-d61c-443f-a65b-d21fe96a405b>2010-09-30 19:53:10 +0000
committermnicholson <mnicholson@f38db490-d61c-443f-a65b-d21fe96a405b>2010-09-30 19:53:10 +0000
commit475318a8c41206ff8267e8af5cf747707edabfdf (patch)
tree40b4a07a5cfa311c12f83897148c93eb01261579 /channels
parent1310db776a5daa975d3ea2445edd8aca0aeed130 (diff)
Merged revisions 289553 via svnmerge from
https://origsvn.digium.com/svn/asterisk/branches/1.6.2 ........ r289553 | mnicholson | 2010-09-30 14:51:27 -0500 (Thu, 30 Sep 2010) | 4 lines Properly handle channel allocation failures duing invites with replaces. ABE-2588 ........ git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.8@289554 f38db490-d61c-443f-a65b-d21fe96a405b
Diffstat (limited to 'channels')
-rw-r--r--channels/chan_sip.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/channels/chan_sip.c b/channels/chan_sip.c
index d222bda61..5e612c052 100644
--- a/channels/chan_sip.c
+++ b/channels/chan_sip.c
@@ -21280,7 +21280,8 @@ static int handle_request_invite(struct sip_pvt *p, struct sip_request *req, int
/* Initialize our tag */
make_our_tag(p->tag, sizeof(p->tag));
- /* First invitation - create the channel */
+ /* First invitation - create the channel. Allocation
+ * failures are handled below. */
c = sip_new(p, AST_STATE_DOWN, S_OR(p->peername, NULL), NULL);
if (cc_recall_core_id != -1) {
ast_setup_cc_recall_datastore(c, cc_recall_core_id);
@@ -21457,7 +21458,7 @@ static int handle_request_invite(struct sip_pvt *p, struct sip_request *req, int
if (!req->ignore && p)
p->lastinvite = seqno;
- if (replace_id) { /* Attended transfer or call pickup - we're the target */
+ if (c && replace_id) { /* Attended transfer or call pickup - we're the target */
if (!ast_strlen_zero(pickup.exten)) {
append_history(p, "Xfer", "INVITE/Replace received");