gdi32: Don't use biSizeImage for a BI_BITFIELDS dib.

This commit is contained in:
Huw Davies 2008-07-29 11:49:58 +01:00 committed by Alexandre Julliard
parent d84ea74ec8
commit 67a5f256c4

View File

@ -61,7 +61,7 @@ static HGLOBAL16 dib_copy(const BITMAPINFO *info, UINT coloruse)
HGLOBAL16 hmem;
INT size;
if (info->bmiHeader.biCompression)
if (info->bmiHeader.biCompression != BI_RGB && info->bmiHeader.biCompression != BI_BITFIELDS)
size = info->bmiHeader.biSizeImage;
else
size = DIB_GetDIBImageBytes(info->bmiHeader.biWidth,