From 5e68ea71f64034c5a37cda1a4269e67b3c47aeff Mon Sep 17 00:00:00 2001 From: "Enrico Weigelt, metux IT consult" Date: Tue, 12 Aug 2025 14:14:39 +0200 Subject: [PATCH] panoramiX: XineramaGetImageData(): scope temporary dimension variables Signed-off-by: Enrico Weigelt, metux IT consult --- Xext/panoramiX.c | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/Xext/panoramiX.c b/Xext/panoramiX.c index 43f070e100..7f7bf5575c 100644 --- a/Xext/panoramiX.c +++ b/Xext/panoramiX.c @@ -1138,7 +1138,7 @@ XineramaGetImageData(DrawablePtr *pDrawables, { RegionRec SrcRegion, GrabRegion; BoxRec SrcBox, *pbox; - int x, y, w, h, i, j, size, sizeNeeded, ScratchPitch, depth; + int i, j, size, sizeNeeded, ScratchPitch, depth; DrawablePtr pDraw = pDrawables[0]; char *ScratchMem = NULL; @@ -1194,8 +1194,8 @@ XineramaGetImageData(DrawablePtr *pDrawables, pbox = RegionRects(&GrabRegion); while (nbox--) { - w = pbox->x2 - pbox->x1; - h = pbox->y2 - pbox->y1; + int w = pbox->x2 - pbox->x1; + int h = pbox->y2 - pbox->y1; ScratchPitch = PixmapBytePad(w, depth); sizeNeeded = ScratchPitch * h; @@ -1211,8 +1211,8 @@ XineramaGetImageData(DrawablePtr *pDrawables, } } - x = pbox->x1 - pWalkDraw->x - screenInfo.screens[i]->x; - y = pbox->y1 - pWalkDraw->y - screenInfo.screens[i]->y; + int x = pbox->x1 - pWalkDraw->x - screenInfo.screens[i]->x; + int y = pbox->y1 - pWalkDraw->y - screenInfo.screens[i]->y; (*pScreen->GetImage) (pWalkDraw, x, y, w, h, format, planemask, ScratchMem);