From dfb28aa9e18a9ef7fccd37fb184f3efa424a5eeb Mon Sep 17 00:00:00 2001 From: Michael Adams Date: Sat, 20 Jan 2024 12:40:12 -0800 Subject: [PATCH] Fixes #371. Made a minor correction to the definition of the refpass_step macro in the JPC codec. The error that was corrected appears not to have resulted in any incorrect code behavior, but it did negatively impact code readability/understandability. --- src/libjasper/jpc/jpc_t1enc.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/libjasper/jpc/jpc_t1enc.c b/src/libjasper/jpc/jpc_t1enc.c index 3c72a3f6..e0a4a32b 100644 --- a/src/libjasper/jpc/jpc_t1enc.c +++ b/src/libjasper/jpc/jpc_t1enc.c @@ -603,6 +603,7 @@ static int jpc_encrawsigpass(jpc_bitstream_t *out, int bitpos, bool vcausalflag, #define refpass_step(fp, dp, bitpos, one, nmsedec, mqenc, vcausalflag) \ { \ + jpc_fix_t d; \ if (((*(fp)) & (JPC_SIG | JPC_VISIT)) == JPC_SIG) { \ (d) = *(dp); \ *(nmsedec) += JPC_GETREFNMSEDEC(JAS_ABS(d), (bitpos) + JPC_NUMEXTRABITS); \ @@ -618,7 +619,6 @@ static int jpc_encrefpass(jpc_mqenc_t *mqenc, int bitpos, jas_matrix_t *flags, c { int i; int one; - int d; jpc_fix_t *fstripestart; jpc_fix_t *fvscanstart; jpc_fix_t *fp;