From f0edc9075539bddff2726065271c86fd7b480c9f Mon Sep 17 00:00:00 2001 From: Jonas Nick Date: Fri, 4 Feb 2022 10:54:11 +0000 Subject: [PATCH] musig: fix number of tweaks in tweak_test --- src/modules/musig/tests_impl.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/modules/musig/tests_impl.h b/src/modules/musig/tests_impl.h index 70512360..aab68615 100644 --- a/src/modules/musig/tests_impl.h +++ b/src/modules/musig/tests_impl.h @@ -883,7 +883,7 @@ void musig_tweak_test(secp256k1_scratch_space *scratch) { * that key. If xonly is set to true, the function f is normalizes the input * point to have an even X-coordinate ("xonly-tweaking"). * Otherwise, the function f is the identity function. */ - for (i = 1; i < N_TWEAKS; i++) { + for (i = 1; i <= N_TWEAKS; i++) { unsigned char tweak[32]; int P_parity; int xonly = secp256k1_testrand_bits(1);