From 01f879d3e3fe5bdcf290b802a3c44a2bdde2b059 Mon Sep 17 00:00:00 2001 From: David Benjamin Date: Sat, 20 Aug 2016 13:55:17 -0400 Subject: Don't check for malloc failure twice. a03f81f4ead24c234dc26e388d86a352685f3948 added a malloc failure check to EVP_PKEY_keygen, but there already was one. Signed-off-by: Kurt Roeckx Reviewed-by: Rich Salz GH: #1473 --- crypto/evp/pmeth_gn.c | 5 ----- 1 file changed, 5 deletions(-) (limited to 'crypto') diff --git a/crypto/evp/pmeth_gn.c b/crypto/evp/pmeth_gn.c index 6d7b5d7242..6a4d3573ff 100644 --- a/crypto/evp/pmeth_gn.c +++ b/crypto/evp/pmeth_gn.c @@ -154,11 +154,6 @@ int EVP_PKEY_keygen(EVP_PKEY_CTX *ctx, EVP_PKEY **ppkey) if (*ppkey == NULL) return -1; - if (*ppkey == NULL) { - EVPerr(EVP_F_EVP_PKEY_KEYGEN, ERR_R_MALLOC_FAILURE); - return -1; - } - ret = ctx->pmeth->keygen(ctx, *ppkey); if (ret <= 0) { EVP_PKEY_free(*ppkey); -- cgit v1.2.3