summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorEirik Aavitsland <eirik.aavitsland@qt.io>2021-06-15 10:44:28 +0200
committerEirik Aavitsland <eirik.aavitsland@qt.io>2021-06-15 14:23:03 +0000
commitf443c9e9d747124a676fc328487dca7c94713df3 (patch)
treed7c0ce181439d24b26e67b924dc8b510e120296b
parent370dd41c9ec7fd66a8989ac8a2c4bc1078aeff44 (diff)
Patch bundled libtiff to compile on Integrity
More recent versions of the compiler works, but for Qt 5.x we support an older version that fails to compile this code. (cherry picked from 5.15 commit) Change-Id: If073e07929eb330766b49087d49531409a7548e5 Reviewed-by: Paul Olav Tvete <paul.tvete@qt.io>
-rw-r--r--src/3rdparty/libtiff/libtiff/tif_fax3.c16
1 files changed, 10 insertions, 6 deletions
diff --git a/src/3rdparty/libtiff/libtiff/tif_fax3.c b/src/3rdparty/libtiff/libtiff/tif_fax3.c
index 0baf7ad..b79f1f3 100644
--- a/src/3rdparty/libtiff/libtiff/tif_fax3.c
+++ b/src/3rdparty/libtiff/libtiff/tif_fax3.c
@@ -327,19 +327,23 @@ Fax3Decode2D(TIFF* tif, uint8_t* buf, tmsize_t occ, uint16_t s)
}
#undef SWAP
-# define FILL(n, cp) \
- for (int32_t ifill = 0; ifill < (n); ++ifill) \
+# define FILL(n, cp) { \
+ int32_t ifill; \
+ for (ifill = 0; ifill < (n); ++ifill) \
{ \
(cp)[ifill] = 0xff; \
} \
- (cp) += (n);
+ (cp) += (n); \
+}
-# define ZERO(n, cp) \
- for (int32_t izero = 0; izero < (n); ++izero) \
+# define ZERO(n, cp) { \
+ int32_t izero; \
+ for (izero = 0; izero < (n); ++izero) \
{ \
(cp)[izero] = 0; \
} \
- (cp) += (n);
+ (cp) += (n); \
+}
/*
* Bit-fill a row according to the white/black