]> git.ipfire.org Git - thirdparty/freeswitch.git/commitdiff
fix for SFSIP-82
authorAnthony Minessale <anthony.minessale@gmail.com>
Thu, 14 Aug 2008 19:44:12 +0000 (19:44 +0000)
committerAnthony Minessale <anthony.minessale@gmail.com>
Thu, 14 Aug 2008 19:44:12 +0000 (19:44 +0000)
git-svn-id: http://svn.freeswitch.org/svn/freeswitch/trunk@9300 d0543943-73ff-0310-b7d9-9358b9ac24b2

src/mod/endpoints/mod_sofia/sofia_glue.c

index 217ad4b8f3259216d3f1b83caafc7bfde66fd965..abc1e5ce01e3d7f9b659ba4832f7b67cfc71a2cd 100644 (file)
@@ -2230,9 +2230,10 @@ uint8_t sofia_glue_negotiate_sdp(switch_core_session_t *session, sdp_session_t *
                                                match = strcasecmp(switch_str_nil(map->rm_encoding), tech_pvt->iananame) ? 0 : 1;
                                        }
 
-                                       if (match) {
-                                               switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_DEBUG, "Our existing codec [%s] is still good, let's keep it\n",
-                                                                                 tech_pvt->rm_encoding);
+                                       if (match && connection->c_address && tech_pvt->remote_sdp_audio_ip && 
+                                               !strcmp(connection->c_address, tech_pvt->remote_sdp_audio_ip) && m->m_port == tech_pvt->remote_sdp_audio_port) {
+                                               switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_DEBUG, "Our existing sdp is still good [%s %s:%d], let's keep it.\n",
+                                                                                 tech_pvt->rm_encoding, tech_pvt->remote_sdp_audio_ip, tech_pvt->remote_sdp_audio_port);
                                                got_audio = 1;
                                                break;
                                        }