From 68c690279cf058547bb6898560fc0cab5b522bc1 Mon Sep 17 00:00:00 2001 From: Steven Tamm Date: Mon, 20 Dec 2004 16:46:17 +0000 Subject: [PATCH] (mac_do_list_fonts): Fix memory leak --- src/ChangeLog | 4 ++++ src/macterm.c | 4 ++-- 2 files changed, 6 insertions(+), 2 deletions(-) diff --git a/src/ChangeLog b/src/ChangeLog index c7af7651f6c..33d6f42799c 100644 --- a/src/ChangeLog +++ b/src/ChangeLog @@ -1,3 +1,7 @@ +2004-12-20 YAMAMOTO Mitsuharu + + * macterm.c (mac_do_list_fonts): Fix memory leak + 2004-12-20 Richard M. Stallman * regex.c (re_match_2_internal) : diff --git a/src/macterm.c b/src/macterm.c index ca15d3c4965..9dae0b54d70 100644 --- a/src/macterm.c +++ b/src/macterm.c @@ -6426,7 +6426,7 @@ mac_do_list_fonts (pattern, maxnames) { font_list = Fcons (fontname, font_list); if (exact || maxnames > 0 && ++n_fonts >= maxnames) - return font_list; + break; } else if (scl_val[XLFD_SCL_PIXEL_SIZE] > 0 && (ptr = strstr (font_name_table[i], "-0-0-75-75-m-0-"))) @@ -6446,7 +6446,7 @@ mac_do_list_fonts (pattern, maxnames) { font_list = Fcons (fontname, font_list); if (exact || maxnames > 0 && ++n_fonts >= maxnames) - return font_list; + break; } } } -- 2.39.5