From ae475079a1cc9064327d0a1f680dd6107db29859 Mon Sep 17 00:00:00 2001 From: erouault Date: Wed, 11 Jan 2017 16:38:26 +0000 Subject: [PATCH 1/8] =?UTF-8?q?*=20libtiff/tif=5Fgetimage.c:=20add=20expli?= =?UTF-8?q?cit=20uint32=20cast=20in=20putagreytile=20to=20avoid=20Undefine?= =?UTF-8?q?dBehaviorSanitizer=20warning.=20Patch=20by=20Nicol=C3=A1s=20Pe?= =?UTF-8?q?=C3=B1a.=20Fixes=20http://bugzilla.maptools.org/show=5Fbug.cgi?= =?UTF-8?q?=3Fid=3D2658?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- libtiff/tif_getimage.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/libtiff/tif_getimage.c b/libtiff/tif_getimage.c index 0f5e932..f5258b3 100644 --- a/libtiff/tif_getimage.c +++ b/libtiff/tif_getimage.c @@ -1305,7 +1305,7 @@ DECLAREContigPutFunc(putagreytile) while (h-- > 0) { for (x = w; x-- > 0;) { - *cp++ = BWmap[*pp][0] & (*(pp+1) << 24 | ~A1); + *cp++ = BWmap[*pp][0] & ((uint32)*(pp+1) << 24 | ~A1); pp += samplesperpixel; } cp += toskew; -- 2.7.4