]> git.ipfire.org Git - thirdparty/freeswitch.git/commitdiff
FS-6829 #resolve
authorAnthony Minessale <anthm@freeswitch.org>
Thu, 18 Sep 2014 21:28:41 +0000 (02:28 +0500)
committerAnthony Minessale <anthm@freeswitch.org>
Thu, 18 Sep 2014 21:28:47 +0000 (02:28 +0500)
src/switch_core_media.c

index 2616237fbe18c74af2c37102b0de6c98bbea66eb..844497cc803803a57ee0cc6c2dd0801422bda06c 100644 (file)
@@ -4103,7 +4103,10 @@ SWITCH_DECLARE(int) switch_core_media_toggle_hold(switch_core_session_t *session
                        switch_channel_mark_hold(session->channel, SWITCH_FALSE);
                        switch_channel_presence(session->channel, "unknown", "unhold", NULL);
 
-                       switch_rtp_clear_flag(a_engine->rtp_session, SWITCH_RTP_FLAG_PAUSE);
+                       if (a_engine->rtp_session) {
+                               switch_rtp_clear_flag(a_engine->rtp_session, SWITCH_RTP_FLAG_PAUSE);
+                       }
+
                        if (v_engine->rtp_session) {
                                switch_rtp_clear_flag(v_engine->rtp_session, SWITCH_RTP_FLAG_PAUSE);
                        }