From a3a3e11acdb473f96a8972ed40cd3310057aec23 Mon Sep 17 00:00:00 2001 From: Sebastian Falbesoner Date: Fri, 1 Dec 2023 01:03:07 +0100 Subject: [PATCH] remove unneeded VERIFY_SETUP uses in ECMULT_CONST_TABLE_GET_GE macro As the fields r->x and r->y are set immediately after (three lines below), there is no need to clear them. --- src/ecmult_const_impl.h | 2 -- 1 file changed, 2 deletions(-) diff --git a/src/ecmult_const_impl.h b/src/ecmult_const_impl.h index ece1edc1b51b2..7dc4aac25d3a9 100644 --- a/src/ecmult_const_impl.h +++ b/src/ecmult_const_impl.h @@ -87,8 +87,6 @@ static void secp256k1_ecmult_const_odd_multiples_table_globalz(secp256k1_ge *pre secp256k1_fe neg_y; \ VERIFY_CHECK((n) < (1U << ECMULT_CONST_GROUP_SIZE)); \ VERIFY_CHECK(index < (1U << (ECMULT_CONST_GROUP_SIZE - 1))); \ - VERIFY_SETUP(secp256k1_fe_clear(&(r)->x)); \ - VERIFY_SETUP(secp256k1_fe_clear(&(r)->y)); \ /* Unconditionally set r->x = (pre)[m].x. r->y = (pre)[m].y. because it's either the correct one * or will get replaced in the later iterations, this is needed to make sure `r` is initialized. */ \ (r)->x = (pre)[m].x; \