summaryrefslogtreecommitdiffstats
path: root/engines/ccgost
diff options
context:
space:
mode:
Diffstat (limited to 'engines/ccgost')
-rw-r--r--engines/ccgost/gost94_keyx.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/engines/ccgost/gost94_keyx.c b/engines/ccgost/gost94_keyx.c
index cae22ca0bc..37c4d656ff 100644
--- a/engines/ccgost/gost94_keyx.c
+++ b/engines/ccgost/gost94_keyx.c
@@ -51,6 +51,8 @@ static int make_cp_exchange_key(BIGNUM *priv_key,EVP_PKEY *pubk, unsigned char *
gost_hash_ctx hash_ctx;
DH *dh = DH_new();
+ if (!dh)
+ return 0;
memset(dh_key,0,128);
dh->g = BN_dup(pubk->pkey.dsa->g);
dh->p = BN_dup(pubk->pkey.dsa->p);