gdi32: Fix a memory leak.

Signed-off-by: Haoyang Chen <chenhaoyang@uniontech.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
(cherry picked from commit 4b9c4e4201)
Signed-off-by: Michael Stefaniuc <mstefani@winehq.org>
This commit is contained in:
Haoyang Chen 2021-05-13 14:17:57 +08:00 committed by Michael Stefaniuc
parent fb53228568
commit 328d834ad9
1 changed files with 2 additions and 1 deletions

View File

@ -1538,9 +1538,10 @@ static UINT parse_aa_pattern( FcPattern *pattern )
static FcPattern *create_family_pattern( const char *name, FcPattern **cached )
{
FcPattern *ret = NULL, *tmp, *pattern = pFcPatternCreate();
FcPattern *ret = NULL, *tmp, *pattern;
FcResult result;
if (*cached) return *cached;
pattern = pFcPatternCreate();
pFcPatternAddString( pattern, FC_FAMILY, (const FcChar8 *)name );
pFcPatternAddString( pattern, FC_NAMELANG, (const FcChar8 *)"en-us" );
pFcPatternAddString( pattern, FC_PRGNAME, (const FcChar8 *)"wine" );