summaryrefslogtreecommitdiffstats
path: root/crypto/init.c
diff options
context:
space:
mode:
authorKurt Roeckx <kurt@roeckx.be>2016-07-12 15:50:06 +0200
committerKurt Roeckx <kurt@roeckx.be>2016-07-20 19:20:53 +0200
commit69588edbaa424beb71c6a9b1be416588232cb78c (patch)
treebc2d601241ea428fac0bc35d215b3964f0fce199 /crypto/init.c
parent8cc44d970ced1004db0727d7a7b3e2709c442e55 (diff)
Check for errors allocating the error strings.
Reviewed-by: Richard Levitte <levitte@openssl.org> GH: #1330
Diffstat (limited to 'crypto/init.c')
-rw-r--r--crypto/init.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/crypto/init.c b/crypto/init.c
index ace11da610..332567eae7 100644
--- a/crypto/init.c
+++ b/crypto/init.c
@@ -92,6 +92,7 @@ DEFINE_RUN_ONCE_STATIC(ossl_init_no_load_crypto_strings)
DEFINE_RUN_ONCE_STATIC(ossl_init_load_crypto_strings)
{
+ int ret = 1;
/*
* OPENSSL_NO_AUTOERRINIT is provided here to prevent at compile time
* pulling in all the error strings during static linking
@@ -101,10 +102,10 @@ DEFINE_RUN_ONCE_STATIC(ossl_init_load_crypto_strings)
fprintf(stderr, "OPENSSL_INIT: ossl_init_load_crypto_strings: "
"err_load_crypto_strings_int()\n");
# endif
- err_load_crypto_strings_int();
+ ret = err_load_crypto_strings_int();
#endif
load_crypto_strings_inited = 1;
- return 1;
+ return ret;
}
static CRYPTO_ONCE add_all_ciphers = CRYPTO_ONCE_STATIC_INIT;