summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorBenny Prijono <bennylp@teluu.com>2010-01-29 22:00:04 +0000
committerBenny Prijono <bennylp@teluu.com>2010-01-29 22:00:04 +0000
commite13dbde5e2e020f31bebd8ca48e10e2c2d3900d3 (patch)
treec343e8577830065eb21109853b3ff30a52913dda
parent988d451bfb7c095a883cd17dba252f3ca0776b0b (diff)
More ticket #1033:
- fix for r3071: added protection for case when TSX_HAS_PENDING_TRANSPORT flag is set to the transaction but pending_tx is NULL, causing crash git-svn-id: http://svn.pjsip.org/repos/pjproject/trunk@3084 74dad513-b988-da41-8d7b-12977e46ad98
-rw-r--r--pjsip/src/pjsip/sip_transaction.c6
1 files changed, 4 insertions, 2 deletions
diff --git a/pjsip/src/pjsip/sip_transaction.c b/pjsip/src/pjsip/sip_transaction.c
index 026220a2..ffffed16 100644
--- a/pjsip/src/pjsip/sip_transaction.c
+++ b/pjsip/src/pjsip/sip_transaction.c
@@ -1131,8 +1131,10 @@ static void tsx_set_state( pjsip_transaction *tsx,
* to ignore that (otherwise we'll get assertion, see
* http://trac.pjsip.org/repos/ticket/1033)
*/
- tsx->pending_tx->mod_data[mod_tsx_layer.mod.id] = NULL;
- tsx->pending_tx = NULL;
+ if (tsx->pending_tx) {
+ tsx->pending_tx->mod_data[mod_tsx_layer.mod.id] = NULL;
+ tsx->pending_tx = NULL;
+ }
tsx->transport_flag &= ~(TSX_HAS_PENDING_TRANSPORT);
}