This commit is contained in:
Anthony Minessale 2014-03-07 06:35:02 +05:00
parent abb83e0b0e
commit 46c5268e09

View File

@ -6059,11 +6059,6 @@ SWITCH_DECLARE(void) switch_core_media_gen_local_sdp(switch_core_session_t *sess
} }
switch_core_session_parse_crypto_prefs(session); switch_core_session_parse_crypto_prefs(session);
switch_core_session_check_outgoing_crypto(session); switch_core_session_check_outgoing_crypto(session);
} else {
if (switch_channel_test_flag(smh->session->channel, CF_DTLS)) {
a_engine->no_crypto = 1;
}
} }
fmtp_out = a_engine->cur_payload_map->fmtp_out; fmtp_out = a_engine->cur_payload_map->fmtp_out;
@ -6240,12 +6235,12 @@ SWITCH_DECLARE(void) switch_core_media_gen_local_sdp(switch_core_session_t *sess
if (a_engine->codec_negotiated) { if (a_engine->codec_negotiated) {
switch_snprintf(buf + strlen(buf), SDPBUFLEN - strlen(buf), "m=audio %d %s", port, switch_snprintf(buf + strlen(buf), SDPBUFLEN - strlen(buf), "m=audio %d %s", port,
get_media_profile_name(session, get_media_profile_name(session, !a_engine->no_crypto &&
((!a_engine->no_crypto || switch_channel_test_flag(session->channel, CF_DTLS)) && (switch_channel_test_flag(session->channel, CF_DTLS) || a_engine->crypto_type != CRYPTO_INVALID)));
a_engine->crypto_type != CRYPTO_INVALID
)));
switch_snprintf(buf + strlen(buf), SDPBUFLEN - strlen(buf), " %d", a_engine->cur_payload_map->pt); switch_snprintf(buf + strlen(buf), SDPBUFLEN - strlen(buf), " %d", a_engine->cur_payload_map->pt);
@ -6555,7 +6550,7 @@ SWITCH_DECLARE(void) switch_core_media_gen_local_sdp(switch_core_session_t *sess
get_media_profile_name(session, get_media_profile_name(session,
(loops == 0 && switch_channel_test_flag(session->channel, CF_SECURE) (loops == 0 && switch_channel_test_flag(session->channel, CF_SECURE)
&& switch_channel_direction(session->channel) == SWITCH_CALL_DIRECTION_OUTBOUND) || && switch_channel_direction(session->channel) == SWITCH_CALL_DIRECTION_OUTBOUND) ||
a_engine->crypto_type != CRYPTO_INVALID)); a_engine->crypto_type != CRYPTO_INVALID || switch_channel_test_flag(session->channel, CF_DTLS)));