summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorBenny Prijono <bennylp@teluu.com>2009-06-25 12:02:46 +0000
committerBenny Prijono <bennylp@teluu.com>2009-06-25 12:02:46 +0000
commitc3ec0081c7a6e5622e9748a48561d064f53e9831 (patch)
treeab866bdd04665a8ed8426a201ed47b4261c5c6c1
parentef65df46ee1615f43734c36a14c9d0254113b697 (diff)
Ticket #846: Crash in 100rel after CANCEL is received and 487 is sent (thanks Gang Liu for the report)
- backported from #845 git-svn-id: http://svn.pjsip.org/repos/pjproject/branches/1.0@2803 74dad513-b988-da41-8d7b-12977e46ad98
-rw-r--r--pjsip/src/pjsip-ua/sip_inv.c7
1 files changed, 6 insertions, 1 deletions
diff --git a/pjsip/src/pjsip-ua/sip_inv.c b/pjsip/src/pjsip-ua/sip_inv.c
index 5d22205e..cd371daf 100644
--- a/pjsip/src/pjsip-ua/sip_inv.c
+++ b/pjsip/src/pjsip-ua/sip_inv.c
@@ -2478,7 +2478,12 @@ static void inv_respond_incoming_cancel(pjsip_inv_session *inv,
if (status == PJ_SUCCESS) {
/* Remove the message body */
tdata->msg->body = NULL;
- pjsip_dlg_send_response(inv->dlg, invite_tsx, tdata);
+ if (inv->options & PJSIP_INV_REQUIRE_100REL) {
+ status = pjsip_100rel_tx_response(inv, tdata);
+ } else {
+ status = pjsip_dlg_send_response(inv->dlg, invite_tsx,
+ tdata);
+ }
}
}