Commit edb48a06 authored by Alexandre Julliard's avatar Alexandre Julliard

gdi32: Allow SetDIBits to use the null driver.

parent 6f066ec1
......@@ -500,7 +500,6 @@ INT WINAPI SetDIBits( HDC hdc, HBITMAP hbitmap, UINT startscan,
{
DC *dc = get_dc_ptr( hdc );
BOOL delete_hdc = FALSE;
PHYSDEV physdev;
BITMAPOBJ *bitmap;
char src_bmibuf[FIELD_OFFSET( BITMAPINFO, bmiColors[256] )];
BITMAPINFO *src_info = (BITMAPINFO *)src_bmibuf;
......@@ -578,11 +577,6 @@ INT WINAPI SetDIBits( HDC hdc, HBITMAP hbitmap, UINT startscan,
if (lines < src.visrect.bottom) src.visrect.bottom = lines;
}
/* Hack to ensure we don't get the nulldrv if the bmp hasn't been selected
into a dc yet */
physdev = GET_DC_PHYSDEV( dc, pCreateBitmap );
if (!BITMAP_SetOwnerDC( hbitmap, physdev )) goto done;
funcs = get_bitmap_funcs( bitmap );
result = lines;
......
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