]> git.ipfire.org Git - thirdparty/freeswitch.git/commitdiff
reset the remote_media ip/port vars more oftern
authorAnthony Minessale <anthony.minessale@gmail.com>
Wed, 25 Nov 2009 23:09:23 +0000 (23:09 +0000)
committerAnthony Minessale <anthony.minessale@gmail.com>
Wed, 25 Nov 2009 23:09:23 +0000 (23:09 +0000)
git-svn-id: http://svn.freeswitch.org/svn/freeswitch/trunk@15676 d0543943-73ff-0310-b7d9-9358b9ac24b2

src/mod/endpoints/mod_sofia/sofia_glue.c

index 643c57e3b987009a89efef1b9b4f6b208e5ee709..dd9293c88f14017a5d98077a7fb0a6f348791843 100644 (file)
@@ -2364,6 +2364,10 @@ switch_status_t sofia_glue_activate_rtp(private_object_t *tech_pvt, switch_rtp_f
                        switch_log_printf(SWITCH_CHANNEL_SESSION_LOG(tech_pvt->session), SWITCH_LOG_DEBUG, "Audio params changed for %s from %s:%d to %s:%d\n", 
                                                          switch_channel_get_name(tech_pvt->channel),
                                                          remote_host, remote_port, tech_pvt->remote_sdp_audio_ip, tech_pvt->remote_sdp_audio_port);
+
+                       switch_snprintf(tmp, sizeof(tmp), "%d", tech_pvt->remote_sdp_audio_port);
+                       switch_channel_set_variable(tech_pvt->channel, SWITCH_REMOTE_MEDIA_IP_VARIABLE, tech_pvt->remote_sdp_audio_ip);
+                       switch_channel_set_variable(tech_pvt->channel, SWITCH_REMOTE_MEDIA_PORT_VARIABLE, tmp);
                }
        }
 
@@ -2560,6 +2564,11 @@ switch_status_t sofia_glue_activate_rtp(private_object_t *tech_pvt, switch_rtp_f
                        switch_channel_set_variable(tech_pvt->channel, SOFIA_SECURE_MEDIA_CONFIRMED_VARIABLE, "true");
                }
 
+
+               switch_snprintf(tmp, sizeof(tmp), "%d", tech_pvt->remote_sdp_audio_port);
+               switch_channel_set_variable(tech_pvt->channel, SWITCH_REMOTE_MEDIA_IP_VARIABLE, tech_pvt->remote_sdp_audio_ip);
+               switch_channel_set_variable(tech_pvt->channel, SWITCH_REMOTE_MEDIA_PORT_VARIABLE, tmp);
+
          video:
 
                sofia_glue_check_video_codecs(tech_pvt);