gdiplus: Fix some memory leaks.

This commit is contained in:
Andrew Talbot 2007-09-25 20:52:58 +01:00 committed by Alexandre Julliard
parent 161821155d
commit dfac0635f6
1 changed files with 2 additions and 0 deletions

View File

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