From ae93bdd8fa743a319d858b44e26793861c7733ce Mon Sep 17 00:00:00 2001 From: Zebediah Figura Date: Mon, 11 Jan 2021 16:11:33 -0600 Subject: [PATCH] gdi32: Do not compare face file names in insert_face_in_family_list() if either is NULL. Wine-Bug: https://bugs.winehq.org/show_bug.cgi?id=50486 Signed-off-by: Zebediah Figura Signed-off-by: Alexandre Julliard (cherry picked from commit 96fdbabc722f95fd9c4051c1d6f73e5f9515afa3) Signed-off-by: Michael Stefaniuc --- dlls/gdi32/font.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/dlls/gdi32/font.c b/dlls/gdi32/font.c index 7f243192cc3..6f50cc92a83 100644 --- a/dlls/gdi32/font.c +++ b/dlls/gdi32/font.c @@ -913,7 +913,7 @@ static BOOL insert_face_in_family_list( struct gdi_font_face *face, struct gdi_f debugstr_w(face->full_name), debugstr_w(family->family_name), cursor->version, face->version ); - if (face->file && !wcsicmp( face->file, cursor->file )) + if (face->file && cursor->file && !wcsicmp( face->file, cursor->file )) { cursor->refcount++; TRACE("Font %s already in list, refcount now %d\n",