Commit 44c2db17 authored by Ken Thomases's avatar Ken Thomases Committed by Alexandre Julliard

winex11.drv: Pass correct coords into X11DRV_InternalFloodFill.

The (x,y) should be relative to the XImage, not the drawable. The (xOrg,yOrg) is what should be relative to the drawable. This fixes a crash when XGetPixel tried to access memory outside the XImage's buffer.
parent d5664881
......@@ -1312,9 +1312,10 @@ X11DRV_ExtFloodFill( X11DRV_PDEVICE *physDev, INT x, INT y, COLORREF color,
wine_tsx11_lock();
XSetFunction( gdi_display, physDev->gc, GXcopy );
X11DRV_InternalFloodFill(image, physDev,
physDev->dc_rect.left + pt.x - rect.left,
physDev->dc_rect.top + pt.y - rect.top,
rect.left, rect.top,
pt.x - rect.left,
pt.y - rect.top,
physDev->dc_rect.left + rect.left,
physDev->dc_rect.top + rect.top,
X11DRV_PALETTE_ToPhysical( physDev, color ),
fillType );
wine_tsx11_unlock();
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment