From 8494c52aa61387f1eac0ec4ede91ed28dfd4ad81 Mon Sep 17 00:00:00 2001 From: tb <> Date: Wed, 22 Jan 2025 12:54:40 +0000 Subject: Use simpler (if a bit weird) dup instead of new + copy ok jsing --- src/lib/libcrypto/ec/ecp_methods.c | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-) (limited to 'src') diff --git a/src/lib/libcrypto/ec/ecp_methods.c b/src/lib/libcrypto/ec/ecp_methods.c index 62966e14d6..8bcff77d0a 100644 --- a/src/lib/libcrypto/ec/ecp_methods.c +++ b/src/lib/libcrypto/ec/ecp_methods.c @@ -1,4 +1,4 @@ -/* $OpenBSD: ecp_methods.c,v 1.40 2025/01/22 09:56:58 jsing Exp $ */ +/* $OpenBSD: ecp_methods.c,v 1.41 2025/01/22 12:54:40 tb Exp $ */ /* Includes code written by Lenka Fibikova * for the OpenSSL project. * Includes code written by Bodo Moeller for the OpenSSL project. @@ -1020,10 +1020,7 @@ ec_mul_ct(const EC_GROUP *group, EC_POINT *r, const BIGNUM *scalar, BN_CTX_start(ctx); - if ((s = EC_POINT_new(group)) == NULL) - goto err; - - if (!EC_POINT_copy(s, point)) + if ((s = EC_POINT_dup(point, group)) == NULL) goto err; EC_POINT_BN_set_flags(s, BN_FLG_CONSTTIME); -- cgit v1.2.3-55-g6feb