From 84c06801530cbd64876a284f726fab505dc83a08 Mon Sep 17 00:00:00 2001 From: Marc Olivier Chouinard Date: Tue, 4 Mar 2014 09:42:17 -0500 Subject: [PATCH] FS-5755 Fix regression if rtp_secure_media=false, it will force encryption. --- src/switch_core_media.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/switch_core_media.c b/src/switch_core_media.c index 5167ea534f..56c3662840 100644 --- a/src/switch_core_media.c +++ b/src/switch_core_media.c @@ -2840,7 +2840,7 @@ SWITCH_DECLARE(uint8_t) switch_core_media_negotiate_sdp(switch_core_session_t *s } if (!switch_channel_test_flag(session->channel, CF_DTLS) && (var = switch_channel_get_variable(session->channel, "rtp_secure_media"))) { - if (strcasecmp(var, "optional")) { + if (!(switch_false(var) || !strcasecmp(var, "optional"))) { needs_crypto = 1; switch_channel_set_variable(session->channel, "rtp_crypto_mandatory", "true");