Commit 034b8d5c authored by Michael Stefaniuc's avatar Michael Stefaniuc Committed by Alexandre Julliard

dwrite: Don't overallocate memory for a BITMAPINFO.

parent c0092bcd
......@@ -165,7 +165,7 @@ static const IDWriteBitmapRenderTargetVtbl rendertargetvtbl = {
static HRESULT create_rendertarget(HDC hdc, UINT32 width, UINT32 height, IDWriteBitmapRenderTarget **target)
{
char bmibuf[sizeof(BITMAPINFO) + 256 * sizeof(RGBQUAD)];
char bmibuf[FIELD_OFFSET(BITMAPINFO, bmiColors[256])];
BITMAPINFO *bmi = (BITMAPINFO*)bmibuf;
struct rendertarget *This;
HBITMAP dib;
......
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