mirror of
git://source.winehq.org/git/wine.git
synced 2024-10-05 02:38:03 +00:00
gdiplus: Don't call GetDeviceCaps for NULL dc.
This commit is contained in:
parent
f20a1bb94f
commit
d41a1f0183
|
@ -519,7 +519,8 @@ static GpStatus alpha_blend_hdc_pixels(GpGraphics *graphics, INT dst_x, INT dst_
|
|||
if(!hbitmap || !temp_bits)
|
||||
goto done;
|
||||
|
||||
if ((GetDeviceCaps(graphics->hdc, TECHNOLOGY) == DT_RASPRINTER &&
|
||||
if ((graphics->hdc &&
|
||||
GetDeviceCaps(graphics->hdc, TECHNOLOGY) == DT_RASPRINTER &&
|
||||
GetDeviceCaps(graphics->hdc, SHADEBLENDCAPS) == SB_NONE) ||
|
||||
fmt & PixelFormatPAlpha)
|
||||
memcpy(temp_bits, src, src_width * src_height * 4);
|
||||
|
|
Loading…
Reference in a new issue