]> git.ipfire.org Git - thirdparty/freeswitch.git/commitdiff
fix srtp neg in rare case
authorAnthony Minessale <anthm@freeswitch.org>
Mon, 8 Apr 2013 18:24:27 +0000 (13:24 -0500)
committerBrian West <brian@freeswitch.org>
Mon, 8 Apr 2013 18:24:39 +0000 (13:24 -0500)
src/switch_core_media.c

index 13c09bdb222ce67c0997653d1b0fd9e80bc43355..6287a694dec55682ce1a101733af82f443911ec1 100644 (file)
@@ -4399,7 +4399,7 @@ static const char *get_media_profile_name(switch_core_session_t *session, int se
                }
        }
 
-       if ((!secure && switch_channel_test_flag(session->channel, CF_SECURE)) || secure) {
+       if (secure) {
                return "RTP/SAVP";
        }
 
@@ -4559,7 +4559,7 @@ static void generate_m(switch_core_session_t *session, char *buf, size_t buflen,
 
        }
 
-       if (!zstr(a_engine->local_dtls_fingerprint.type)) {
+       if (!zstr(a_engine->local_dtls_fingerprint.type) && secure) {
                switch_snprintf(buf + strlen(buf), buflen - strlen(buf), "a=fingerprint:%s %s\n", a_engine->local_dtls_fingerprint.type, 
                                                a_engine->local_dtls_fingerprint.str);
        }