summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorLiong Sauw Ming <ming@teluu.com>2016-12-06 10:58:48 +0000
committerLiong Sauw Ming <ming@teluu.com>2016-12-06 10:58:48 +0000
commit1b6df9b374d9e31d88854d5a270b48e26e55691e (patch)
treef0810d1437aaf8b57950b9c21c6096700d8d0d8a
parentcd616a16c522847efe0942b20d918219fed73d0e (diff)
Re #1982: Cleanup call setting flags even if callbacks on_call_tx/rx_offer() not implemented
Otherwise this could cause media to be unintentionally reinitialized on re-INVITEs/updates. Refer to ticket #1793. git-svn-id: http://svn.pjsip.org/repos/pjproject/trunk@5492 74dad513-b988-da41-8d7b-12977e46ad98
-rw-r--r--pjsip/src/pjsua-lib/pjsua_call.c7
1 files changed, 4 insertions, 3 deletions
diff --git a/pjsip/src/pjsua-lib/pjsua_call.c b/pjsip/src/pjsua-lib/pjsua_call.c
index 2089fc16..b3a07184 100644
--- a/pjsip/src/pjsua-lib/pjsua_call.c
+++ b/pjsip/src/pjsua-lib/pjsua_call.c
@@ -4111,13 +4111,13 @@ static void pjsua_call_on_rx_offer(pjsip_inv_session *inv,
goto on_return;
}
+ cleanup_call_setting_flag(&call->opt);
+
if (pjsua_var.ua_cfg.cb.on_call_rx_offer) {
pjsip_status_code code = PJSIP_SC_OK;
pjsua_call_setting opt;
- cleanup_call_setting_flag(&call->opt);
opt = call->opt;
-
(*pjsua_var.ua_cfg.cb.on_call_rx_offer)(call->index, offer, NULL,
&code, &opt);
@@ -4243,8 +4243,9 @@ static void pjsua_call_on_create_offer(pjsip_inv_session *inv,
}
#endif
+ cleanup_call_setting_flag(&call->opt);
+
if (pjsua_var.ua_cfg.cb.on_call_tx_offer) {
- cleanup_call_setting_flag(&call->opt);
(*pjsua_var.ua_cfg.cb.on_call_tx_offer)(call->index, NULL,
&call->opt);
}