This was previously used uninitialized in bitmapinfoheader_from_user_bitmapinfo
Signed-off-by: Sven Baars sven.wine@gmail.com --- dlls/winex11.drv/window.c | 1 + 1 file changed, 1 insertion(+)
diff --git a/dlls/winex11.drv/window.c b/dlls/winex11.drv/window.c index 0a4f118c34..37531d8595 100644 --- a/dlls/winex11.drv/window.c +++ b/dlls/winex11.drv/window.c @@ -545,6 +545,7 @@ static BOOL create_icon_pixmaps( HDC hdc, const ICONINFO *icon, Pixmap *icon_ret
info->bmiHeader.biSize = sizeof(BITMAPINFOHEADER); info->bmiHeader.biBitCount = 0; + info->bmiHeader.biCompression = BI_RGB; if (!(lines = GetDIBits( hdc, icon->hbmColor, 0, 0, NULL, info, DIB_RGB_COLORS ))) goto failed; if (!(bits.ptr = HeapAlloc( GetProcessHeap(), 0, info->bmiHeader.biSizeImage ))) goto failed; if (!GetDIBits( hdc, icon->hbmColor, 0, lines, bits.ptr, info, DIB_RGB_COLORS )) goto failed;
Sven Baars sven.wine@gmail.com writes:
This was previously used uninitialized in bitmapinfoheader_from_user_bitmapinfo
In theory GetDIBits() should be fixed, but there's no actual problem so it's probably not worth the trouble. We definitely don't want to change the caller to hide the bug.
On 18-09-18 12:35, Alexandre Julliard wrote:
Sven Baars sven.wine@gmail.com writes:
This was previously used uninitialized in bitmapinfoheader_from_user_bitmapinfo
In theory GetDIBits() should be fixed, but there's no actual problem so it's probably not worth the trouble. We definitely don't want to change the caller to hide the bug.
Ah, I just checked the documentation and found that this is actually a valid way to call GetDIBits indeed. And I also found out that there is already a bug report about this specific issue. I'll check more carefully next time. Sorry for the noise!
Sven