summaryrefslogtreecommitdiffstats
path: root/providers/implementations/kdfs/pbkdf2.c
diff options
context:
space:
mode:
Diffstat (limited to 'providers/implementations/kdfs/pbkdf2.c')
-rw-r--r--providers/implementations/kdfs/pbkdf2.c8
1 files changed, 2 insertions, 6 deletions
diff --git a/providers/implementations/kdfs/pbkdf2.c b/providers/implementations/kdfs/pbkdf2.c
index ff6a6d4a21..2506a96f7c 100644
--- a/providers/implementations/kdfs/pbkdf2.c
+++ b/providers/implementations/kdfs/pbkdf2.c
@@ -72,10 +72,8 @@ static void *kdf_pbkdf2_new_no_init(void *provctx)
return NULL;
ctx = OPENSSL_zalloc(sizeof(*ctx));
- if (ctx == NULL) {
- ERR_raise(ERR_LIB_PROV, ERR_R_MALLOC_FAILURE);
+ if (ctx == NULL)
return NULL;
- }
ctx->provctx = provctx;
return ctx;
}
@@ -163,10 +161,8 @@ static int pbkdf2_set_membuf(unsigned char **buffer, size_t *buflen,
*buflen = 0;
if (p->data_size == 0) {
- if ((*buffer = OPENSSL_malloc(1)) == NULL) {
- ERR_raise(ERR_LIB_PROV, ERR_R_MALLOC_FAILURE);
+ if ((*buffer = OPENSSL_malloc(1)) == NULL)
return 0;
- }
} else if (p->data != NULL) {
if (!OSSL_PARAM_get_octet_string(p, (void **)buffer, 0, buflen))
return 0;