fix packet storm of vid refresh in edge case

This commit is contained in:
Anthony Minessale
2012-01-24 11:38:41 -06:00
parent 8802260acc
commit 224f4c0f8a
2 changed files with 7 additions and 16 deletions
+7 -5
View File
@@ -7137,11 +7137,13 @@ void sofia_handle_sip_i_info(nua_t *nua, sofia_profile_t *profile, nua_handle_t
if (!strncasecmp(sip->sip_content_type->c_type, "application", 11) && !strcasecmp(sip->sip_content_type->c_subtype, "media_control+xml")) {
switch_core_session_t *other_session;
switch_channel_set_flag(channel, CF_VIDEO_REFRESH_REQ);
if (switch_core_session_get_partner(session, &other_session) == SWITCH_STATUS_SUCCESS) {
sofia_glue_build_vid_refresh_message(other_session, sip->sip_payload->pl_data);
switch_core_session_rwunlock(other_session);
if (switch_channel_test_flag(channel, CF_VIDEO)) {
if (switch_core_session_get_partner(session, &other_session) == SWITCH_STATUS_SUCCESS) {
sofia_glue_build_vid_refresh_message(other_session, sip->sip_payload->pl_data);
switch_core_session_rwunlock(other_session);
} else {
switch_channel_set_flag(channel, CF_VIDEO_REFRESH_REQ);
}
}
} else if (!strncasecmp(sip->sip_content_type->c_type, "application", 11) && !strcasecmp(sip->sip_content_type->c_subtype, "dtmf-relay")) {