From 75da7a821c9f4678a8fb12a9c2ecd63e132006de Mon Sep 17 00:00:00 2001 From: tb Date: Wed, 26 Jul 2023 12:16:55 +0000 Subject: [PATCH] Garbage collect the unused order in check_discriminant() ok jsing --- lib/libcrypto/ec/ecp_smpl.c | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/lib/libcrypto/ec/ecp_smpl.c b/lib/libcrypto/ec/ecp_smpl.c index 1a467d4f8f6..0fd751a2a34 100644 --- a/lib/libcrypto/ec/ecp_smpl.c +++ b/lib/libcrypto/ec/ecp_smpl.c @@ -1,4 +1,4 @@ -/* $OpenBSD: ecp_smpl.c,v 1.51 2023/07/26 12:16:13 tb Exp $ */ +/* $OpenBSD: ecp_smpl.c,v 1.52 2023/07/26 12:16:55 tb Exp $ */ /* Includes code written by Lenka Fibikova * for the OpenSSL project. * Includes code written by Bodo Moeller for the OpenSSL project. @@ -203,7 +203,7 @@ ec_GFp_simple_group_get_degree(const EC_GROUP *group) int ec_GFp_simple_group_check_discriminant(const EC_GROUP *group, BN_CTX *ctx) { - BIGNUM *p, *a, *b, *order, *tmp_1, *tmp_2; + BIGNUM *p, *a, *b, *tmp_1, *tmp_2; int ret = 0; BN_CTX_start(ctx); @@ -218,8 +218,6 @@ ec_GFp_simple_group_check_discriminant(const EC_GROUP *group, BN_CTX *ctx) goto err; if ((tmp_2 = BN_CTX_get(ctx)) == NULL) goto err; - if ((order = BN_CTX_get(ctx)) == NULL) - goto err; if (!EC_GROUP_get_curve(group, p, a, b, ctx)) goto err; -- 2.20.1