From 9fa45a66de8daf17d3ab3e4e5e70e8499b6e5073 Mon Sep 17 00:00:00 2001 From: Martin Milata Date: Thu, 4 Nov 2021 11:51:56 +0100 Subject: [PATCH] Fix C compilation with -Werror=unused-parameter and without asserts. --- c/qrcodegen.c | 1 + 1 file changed, 1 insertion(+) diff --git a/c/qrcodegen.c b/c/qrcodegen.c index 31219a7..14b0406 100644 --- a/c/qrcodegen.c +++ b/c/qrcodegen.c @@ -712,6 +712,7 @@ static long getPenaltyScore(const uint8_t qrcode[]) { // Can only be called immediately after a white run is added, and // returns either 0, 1, or 2. A helper function for getPenaltyScore(). static int finderPenaltyCountPatterns(const int runHistory[7], int qrsize) { + (void)qrsize; int n = runHistory[1]; assert(n <= qrsize * 3); bool core = n > 0 && runHistory[2] == n && runHistory[3] == n * 3 && runHistory[4] == n && runHistory[5] == n;