]> git.ipfire.org Git - thirdparty/freeswitch.git/commitdiff
[Core] switch_core_media: Correct srtp_remote_audio_crypto_key variable
authorajay-sabat <33070898+ajay-sabat@users.noreply.github.com>
Wed, 11 Nov 2020 21:29:48 +0000 (13:29 -0800)
committerGitHub <noreply@github.com>
Wed, 11 Nov 2020 21:29:48 +0000 (01:29 +0400)
src/switch_core_media.c

index e0416e07684f4f9dd5ee0c5b9a07734ed7980a4a..14497247821c834a55827d4c6d56389383b6912d 100644 (file)
@@ -1637,8 +1637,9 @@ static void switch_core_session_get_recovery_crypto_key(switch_core_session_t *s
        } else return;
 
        if ((tmp = switch_channel_get_variable(session->channel, keyvar))) {
-               if ((tmp = switch_channel_get_variable(session->channel, ctypevar))) {
-                       engine->crypto_type = switch_core_media_crypto_str2type(tmp);
+               const char *ct;
+               if ((ct = switch_channel_get_variable(session->channel, ctypevar))) {
+                       engine->crypto_type = switch_core_media_crypto_str2type(ct);
                }
 
                engine->ssec[engine->crypto_type].remote_crypto_key = switch_core_session_strdup(session, tmp);