aboutsummaryrefslogtreecommitdiffstats
path: root/lib/crypto/c_src/engine.c
diff options
context:
space:
mode:
authorHans Nilsson <[email protected]>2019-03-21 15:14:19 +0100
committerHans Nilsson <[email protected]>2019-03-21 15:14:19 +0100
commite739ec80b5546e8d04f08c1f4a6c0067be2c13a7 (patch)
tree924e44691620e506c84f483e134706d046e97aaa /lib/crypto/c_src/engine.c
parentc75fa5f4a484bc82083b06e7d10a197b2a3fbddc (diff)
parent7188527f1465c715c7e71e5477f4116f27202288 (diff)
downloadotp-e739ec80b5546e8d04f08c1f4a6c0067be2c13a7.tar.gz
otp-e739ec80b5546e8d04f08c1f4a6c0067be2c13a7.tar.bz2
otp-e739ec80b5546e8d04f08c1f4a6c0067be2c13a7.zip
Merge branch 'hans/crypto/use_openssl_NO-flags/OTP-15683'
* hans/crypto/use_openssl_NO-flags/OTP-15683: crypto: Fixup unused label warning crypto: Fixup 'break strict-aliasing rules' warning crypto: Fixup 'break strict-aliasing rules' warning crypto: Fixup the ripemd160 macro chaos crypto: Test suite fix for unavailable CMAC crypto: Handle additional OPENSSL_NO_* flags
Diffstat (limited to 'lib/crypto/c_src/engine.c')
-rw-r--r--lib/crypto/c_src/engine.c10
1 files changed, 4 insertions, 6 deletions
diff --git a/lib/crypto/c_src/engine.c b/lib/crypto/c_src/engine.c
index 7ffbb9e70d..ea5d9a588f 100644
--- a/lib/crypto/c_src/engine.c
+++ b/lib/crypto/c_src/engine.c
@@ -106,15 +106,13 @@ int init_engine_ctx(ErlNifEnv *env) {
(ErlNifResourceDtor*) engine_ctx_dtor,
ERL_NIF_RT_CREATE|ERL_NIF_RT_TAKEOVER,
NULL);
- if (engine_ctx_rtype == NULL)
- goto err;
+ if (engine_ctx_rtype == NULL) {
+ PRINTF_ERR0("CRYPTO: Could not open resource type 'ENGINE_CTX'");
+ return 0;
+ }
#endif
return 1;
-
- err:
- PRINTF_ERR0("CRYPTO: Could not open resource type 'ENGINE_CTX'");
- return 0;
}
ERL_NIF_TERM engine_by_id_nif(ErlNifEnv* env, int argc, const ERL_NIF_TERM argv[])