Commit fbdf0299 authored by Matt Caswell's avatar Matt Caswell
Browse files

Free any existing SRTP connection profile



When setting a new SRTP connection profile using
SSL_CTX_set_tlsext_use_srtp() or SSL_set_tlsext_use_srtp() we should
free any existing profile first to avoid a memory leak.

Reviewed-by: default avatarKurt Roeckx <kurt@openssl.org>
parent 9921b7b6
Loading
Loading
Loading
Loading
+2 −0
Original line number Diff line number Diff line
@@ -197,6 +197,8 @@ static int ssl_ctx_make_profiles(const char *profiles_string,
            ptr = col + 1;
    } while (col);

    sk_SRTP_PROTECTION_PROFILE_free(*out);

    *out = profiles;

    return 0;