diff --git a/src/ssl.c b/src/ssl.c index b11ed59a7e..8a10559da4 100644 --- a/src/ssl.c +++ b/src/ssl.c @@ -2073,6 +2073,13 @@ int wolfSSL_CTX_set_tlsext_use_srtp(WOLFSSL_CTX* ctx, const char* profile_str) if (ctx != NULL) { ret = DtlsSrtpSelProfiles(&ctx->dtlsSrtpProfiles, profile_str); } + + if (ret == WOLFSSL_FAILURE) { + ret = 1; + } else { + ret = 0; + } + return ret; } int wolfSSL_set_tlsext_use_srtp(WOLFSSL* ssl, const char* profile_str) @@ -2081,6 +2088,13 @@ int wolfSSL_set_tlsext_use_srtp(WOLFSSL* ssl, const char* profile_str) if (ssl != NULL) { ret = DtlsSrtpSelProfiles(&ssl->dtlsSrtpProfiles, profile_str); } + + if (ret == WOLFSSL_FAILURE) { + ret = 1; + } else { + ret = 0; + } + return ret; }