From 7e15e5d5c3b89a4938066bf2a442b497c0eed78e Mon Sep 17 00:00:00 2001 From: David Hammerton Date: Sat, 4 May 2002 18:32:48 +0000 Subject: [PATCH] In initial dibsection creation, the dibsection should always be in appmod because the app memory is initialized to zero if no offset/section is specified, while the DIBitmap is not. --- graphics/x11drv/dib.c | 12 ++---------- 1 file changed, 2 insertions(+), 10 deletions(-) diff --git a/graphics/x11drv/dib.c b/graphics/x11drv/dib.c index 28057c1d2d3..7ae43050d6c 100644 --- a/graphics/x11drv/dib.c +++ b/graphics/x11drv/dib.c @@ -5793,16 +5793,8 @@ HBITMAP X11DRV_DIB_CreateDIBSection( InitializeCriticalSection(&(dib->lock)); if (VIRTUAL_SetFaultHandler(bm.bmBits, X11DRV_DIB_FaultHandler, (LPVOID)res)) { - if (section || offset) - { - X11DRV_DIB_DoProtectDIBSection( bmp, PAGE_READWRITE ); - if (dib) dib->status = DIB_Status_AppMod; - } - else - { - X11DRV_DIB_DoProtectDIBSection( bmp, PAGE_READONLY ); - if (dib) dib->status = DIB_Status_InSync; - } + X11DRV_DIB_DoProtectDIBSection( bmp, PAGE_READWRITE ); + if (dib) dib->status = DIB_Status_AppMod; } }