diff options
author | Tomas Mraz <tomas@openssl.org> | 2021-03-16 12:19:38 +0100 |
---|---|---|
committer | Tomas Mraz <tomas@openssl.org> | 2021-03-16 13:15:18 +0100 |
commit | 2217d4c9ccde174a66cc4022c7d65614379b2ae7 (patch) | |
tree | eefc52b76374a165bd9d57866811311d82ce847b /crypto | |
parent | a23deef2812a1ffa816aacb85f3e9b7ffb504ef5 (diff) |
core_get_libctx: use assert() instead of ossl_assert()
Using ossl_assert makes the build fail with --strict-warnings
because the ossl_assert is declared with warn_unused_result.
Reviewed-by: Matt Caswell <matt@openssl.org>
(Merged from https://github.com/openssl/openssl/pull/14571)
Diffstat (limited to 'crypto')
-rw-r--r-- | crypto/provider_core.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/crypto/provider_core.c b/crypto/provider_core.c index 64bed25e04..cd295809be 100644 --- a/crypto/provider_core.c +++ b/crypto/provider_core.c @@ -7,6 +7,7 @@ * https://www.openssl.org/source/license.html */ +#include <assert.h> #include <openssl/core.h> #include <openssl/core_dispatch.h> #include <openssl/core_names.h> @@ -1118,7 +1119,7 @@ static OPENSSL_CORE_CTX *core_get_libctx(const OSSL_CORE_HANDLE *handle) * that does not apply here. Here |prov| == NULL can happen only in * case of a coding error. */ - (void)ossl_assert(prov != NULL); + assert(prov != NULL); return (OPENSSL_CORE_CTX *)prov->libctx; } |