diff options
author | Benny Prijono <bennylp@teluu.com> | 2009-04-26 11:02:04 +0000 |
---|---|---|
committer | Benny Prijono <bennylp@teluu.com> | 2009-04-26 11:02:04 +0000 |
commit | b757220012cfbb65f835982be24a988d911ce1fb (patch) | |
tree | e6a1b6a3a1bbe067dd265b65a8d9051c442254e2 /pjsip/src/pjsip-ua | |
parent | 0d88d0975fe2a236bb99516e35c2290a3587d4bd (diff) |
Fixed ticket #503: Handle the case when CANCEL is responded with 200/OK but 487 is not sent
- added new API pjsip_tsx_set_timeout()
- set 64*T1 timeout after CANCEL is initiated
- also added SIPp scenario to simulate the UAS
git-svn-id: http://svn.pjsip.org/repos/pjproject/trunk@2646 74dad513-b988-da41-8d7b-12977e46ad98
Diffstat (limited to 'pjsip/src/pjsip-ua')
-rw-r--r-- | pjsip/src/pjsip-ua/sip_inv.c | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/pjsip/src/pjsip-ua/sip_inv.c b/pjsip/src/pjsip-ua/sip_inv.c index a54a5f36..67d560b2 100644 --- a/pjsip/src/pjsip-ua/sip_inv.c +++ b/pjsip/src/pjsip-ua/sip_inv.c @@ -1886,6 +1886,14 @@ PJ_DEF(pj_status_t) pjsip_inv_end_session( pjsip_inv_session *inv, status = pjsip_endpt_create_cancel(inv->dlg->endpt, inv->invite_tsx->last_tx, &tdata); + if (status != PJ_SUCCESS) + return status; + + /* Set timeout for the INVITE transaction, in case UAS is not + * able to respond the INVITE with 487 final response. The + * timeout value is 64*T1. + */ + pjsip_tsx_set_timeout(inv->invite_tsx, 64 * pjsip_cfg()->tsx.t1); } else { |