[PATCH] gdi32: Fix gdi font leak in CreateScalableFontResourceW.
Rémi Bernon
rbernon at codeweavers.com
Wed Dec 9 14:41:27 CST 2020
Wine-Bug: https://bugs.winehq.org/show_bug.cgi?id=50273
Signed-off-by: Rémi Bernon <rbernon at codeweavers.com>
---
dlls/gdi32/font.c | 1 +
1 file changed, 1 insertion(+)
diff --git a/dlls/gdi32/font.c b/dlls/gdi32/font.c
index 9fa0f45ec4b..e76bb772eea 100644
--- a/dlls/gdi32/font.c
+++ b/dlls/gdi32/font.c
@@ -6887,6 +6887,7 @@ BOOL WINAPI CreateScalableFontResourceW( DWORD hidden, LPCWSTR resource_file,
fontdir.dfReserved = 0;
WideCharToMultiByte( CP_ACP, 0, (WCHAR *)font->otm.otmpFamilyName, -1,
fontdir.szFaceName, LF_FACESIZE, NULL, NULL );
+ free_gdi_font( font );
if (hidden) fontdir.dfType |= 0x80;
return create_fot( resource_file, font_file, &fontdir );
--
2.29.2
More information about the wine-devel
mailing list