From 30b0378008895e5d9c938761aca424dd28b04e0b Mon Sep 17 00:00:00 2001 From: Gilles Peskine Date: Tue, 22 Aug 2023 11:06:47 +0200 Subject: [PATCH] Fix off-by-one error The value of p after adding the last entry in the gap table is not used. Signed-off-by: Gilles Peskine --- library/bignum.c | 1 + 1 file changed, 1 insertion(+) diff --git a/library/bignum.c b/library/bignum.c index f84b2e7ce..3724571b2 100644 --- a/library/bignum.c +++ b/library/bignum.c @@ -2194,6 +2194,7 @@ static const unsigned char small_prime_gaps[] = { 14, 4, 2, 4, 14, 4, 2, 4, 20, 4, 8, 10, 8, 4, 6, 6, 14, 4, 6, 6, 8, 6, /*reaches 997*/ + 0 /* the last entry is effectively unused */ }; /*