diff options
author | Pauli <pauli@openssl.org> | 2022-01-10 11:31:45 +1100 |
---|---|---|
committer | Pauli <pauli@openssl.org> | 2022-01-12 20:10:21 +1100 |
commit | 3831351da50b7ce07edba88056394a7a33c5e5d5 (patch) | |
tree | 2f2d78d0f109183569244eb5e64e414acc14ccbc /crypto | |
parent | 291c5b3e39f4c98e61cf7f65056fe49780d1f0ac (diff) |
param build: add errors to failure returns
Reviewed-by: Richard Levitte <levitte@openssl.org>
(Merged from https://github.com/openssl/openssl/pull/17440)
Diffstat (limited to 'crypto')
-rw-r--r-- | crypto/param_build.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/crypto/param_build.c b/crypto/param_build.c index eaece0026d..a86f4baf17 100644 --- a/crypto/param_build.c +++ b/crypto/param_build.c @@ -78,8 +78,10 @@ static int param_push_num(OSSL_PARAM_BLD *bld, const char *key, { OSSL_PARAM_BLD_DEF *pd = param_push(bld, key, size, size, type, 0); - if (pd == NULL) + if (pd == NULL) { + ERR_raise(ERR_LIB_CRYPTO, ERR_R_PASSED_NULL_PARAMETER); return 0; + } if (size > sizeof(pd->num)) { ERR_raise(ERR_LIB_CRYPTO, CRYPTO_R_TOO_MANY_BYTES); return 0; |