aboutsummaryrefslogtreecommitdiffstats
path: root/engines/e_chil.c
diff options
context:
space:
mode:
Diffstat (limited to 'engines/e_chil.c')
-rw-r--r--engines/e_chil.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/engines/e_chil.c b/engines/e_chil.c
index 69d49d7d3a88..72d14fe383a4 100644
--- a/engines/e_chil.c
+++ b/engines/e_chil.c
@@ -839,6 +839,10 @@ static EVP_PKEY *hwcrhk_load_privkey(ENGINE *eng, const char *key_id,
bn_fix_top(rtmp->n);
res = EVP_PKEY_new();
+ if (res == NULL) {
+ HWCRHKerr(HWCRHK_F_HWCRHK_LOAD_PRIVKEY, HWCRHK_R_CHIL_ERROR);
+ goto err;
+ }
EVP_PKEY_assign_RSA(res, rtmp);
# endif