From 9e27e5706ea319ff07a797df0a2ffb03d11bc287 Mon Sep 17 00:00:00 2001 From: Timo Kreuzer Date: Wed, 12 Jan 2011 00:26:20 +0000 Subject: [PATCH] [WIN32K] Don't trat BI_BITFIELDS as compressed format in DIB_CreateDIBSection. Fixes KSStudio. Why it was introduced by r48359? I don't know. It was broken before. I refrain from making any more comments about that piece of ... code. See issue #5781 for more details. svn path=/trunk/; revision=50362 --- reactos/subsystems/win32/win32k/objects/dibobj.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/reactos/subsystems/win32/win32k/objects/dibobj.c b/reactos/subsystems/win32/win32k/objects/dibobj.c index ba854d29d93..7a38ba5dbb9 100644 --- a/reactos/subsystems/win32/win32k/objects/dibobj.c +++ b/reactos/subsystems/win32/win32k/objects/dibobj.c @@ -1424,7 +1424,7 @@ DIB_CreateDIBSection( // Get storage location for DIB bits. Only use biSizeImage if it's valid and // we're dealing with a compressed bitmap. Otherwise, use width * height. - totalSize = bi->biSizeImage && bi->biCompression != BI_RGB + totalSize = bi->biSizeImage && bi->biCompression != BI_RGB && bi->biCompression != BI_BITFIELDS ? bi->biSizeImage : (ULONG)(bm.bmWidthBytes * effHeight); if (section)