Commit dfac0635 authored by Andrew Talbot's avatar Andrew Talbot Committed by Alexandre Julliard

gdiplus: Fix some memory leaks.

parent 16182115
...@@ -1418,6 +1418,7 @@ GpStatus WINGDIPAPI GdipDrawString(GpGraphics *graphics, GDIPCONST WCHAR *string ...@@ -1418,6 +1418,7 @@ GpStatus WINGDIPAPI GdipDrawString(GpGraphics *graphics, GDIPCONST WCHAR *string
break; break;
} }
GdipFree(stringdup);
DeleteObject(rgn); DeleteObject(rgn);
DeleteObject(gdifont); DeleteObject(gdifont);
...@@ -1827,6 +1828,7 @@ GpStatus WINGDIPAPI GdipMeasureString(GpGraphics *graphics, ...@@ -1827,6 +1828,7 @@ GpStatus WINGDIPAPI GdipMeasureString(GpGraphics *graphics,
bounds->Width = (REAL)max_width; bounds->Width = (REAL)max_width;
bounds->Height = (REAL) min(height, nheight); bounds->Height = (REAL) min(height, nheight);
GdipFree(stringdup);
DeleteObject(SelectObject(graphics->hdc, oldfont)); DeleteObject(SelectObject(graphics->hdc, oldfont));
return Ok; return Ok;
......
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