From c88790135c2e5050a8221bf0c56bbc5bd8d3fde2 Mon Sep 17 00:00:00 2001 From: Lauri Kasanen Date: Wed, 19 Mar 2014 11:38:52 +0200 Subject: [PATCH] mi: miPutImage with XYPixmap failed at depth 32 on 64-bit machines 64-bit patch by Keith Packard. --- mi/mibitblt.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/mi/mibitblt.c b/mi/mibitblt.c index 30f003c..dfd2763 100644 --- a/mi/mibitblt.c +++ b/mi/mibitblt.c @@ -791,7 +791,7 @@ miPutImage(pDraw, pGC, depth, x, y, w, h, leftPad, format, pImage) DoChangeGC(pGC, GCForeground | GCBackground, gcv, 0); bytesPer = (long)h * BitmapBytePad(w + leftPad); - for (i = 1 << (depth-1); i != 0; i >>= 1, pImage += bytesPer) + for (i = (unsigned long) 1 << (depth-1); i != 0; i >>= 1, pImage += bytesPer) { if (i & oldPlanemask) {