From 3952a97f6a2f9586b2cb88c3a352a29e79d612ca Mon Sep 17 00:00:00 2001 From: Nanang Izzuddin Date: Mon, 21 May 2012 12:39:39 +0000 Subject: Fix #1511: destroy the media transport of the removed media. git-svn-id: http://svn.pjsip.org/repos/pjproject/trunk@4132 74dad513-b988-da41-8d7b-12977e46ad98 --- pjsip/src/pjsua-lib/pjsua_media.c | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/pjsip/src/pjsua-lib/pjsua_media.c b/pjsip/src/pjsua-lib/pjsua_media.c index 9e2c4c23..3e83b6a1 100644 --- a/pjsip/src/pjsua-lib/pjsua_media.c +++ b/pjsip/src/pjsua-lib/pjsua_media.c @@ -2232,6 +2232,12 @@ pj_status_t pjsua_media_channel_update(pjsua_call_id call_id, /* This may happen when remote removed any SDP media lines in * its re-offer. */ + if (call_med->tp) { + /* Close the media transport */ + pjsua_set_media_tp_state(call_med, PJSUA_MED_TP_NULL); + pjmedia_transport_close(call_med->tp); + call_med->tp = call_med->tp_orig = NULL; + } continue; #if 0 /* Something is wrong */ -- cgit v1.2.3