diff --git a/fix_memleak_in_function_DlgCreate8-5491.patch b/fix_memleak_in_function_DlgCreate8-5491.patch new file mode 100644 index 0000000..9af06f8 --- /dev/null +++ b/fix_memleak_in_function_DlgCreate8-5491.patch @@ -0,0 +1,31 @@ +From 701e4d7569d6bd777704ab3364d7d1c519d89a91 Mon Sep 17 00:00:00 2001 +From: zhailiangliang +Date: Mon, 4 Nov 2024 08:56:07 +0000 +Subject: [PATCH] fix memleak in function DlgCreate8 + +--- + gdraw/gaskdlg.c | 9 +++++---- + 1 file changed, 5 insertions(+), 4 deletions(-) + +diff --git a/gdraw/gaskdlg.c b/gdraw/gaskdlg.c +index 3563361796..8178be14c8 100644 +--- a/gdraw/gaskdlg.c ++++ b/gdraw/gaskdlg.c +@@ -209,12 +209,13 @@ static GWindow DlgCreate8(const char *title,const char *question,va_list ap, + extern GBox _GGadget_defaultbutton_box; + + if ( d!=NULL ) +- memset(d,0,sizeof(*d)); ++ memset(d,0,sizeof(*d)); + buf = vsmprintf(question, ap); + if ( screen_display==NULL ) { +- fprintf(stderr, "%s\n", buf ); +- if ( d!=NULL ) d->done = true; +-return( NULL ); ++ fprintf(stderr, "%s\n", buf); ++ if ( d!=NULL ) d->done = true; ++ free(buf); ++ return( NULL ); + } + ubuf = utf82u_copy(buf); + free(buf); diff --git a/fontforge.spec b/fontforge.spec index 7dd5d58..2696d40 100644 --- a/fontforge.spec +++ b/fontforge.spec @@ -2,7 +2,7 @@ Name: fontforge Version: 20230101 -Release: 14%{?dist} +Release: 16%{?dist} Summary: Outline and bitmap font editor License: GPL-3.0-or-later @@ -14,6 +14,8 @@ Patch0: 0001-Fix-errors-in-French-and-Italian-translations.patch # Fixes CVE-2024-25081 and CVE-2024-25082 Patch1: https://patch-diff.githubusercontent.com/raw/fontforge/fontforge/pull/5367.patch#/Fix_Splinefont_shell_invocation.patch Patch2: pyconfig.patch +# https://github.com/fontforge/fontforge/pull/5491 +Patch3: fix_memleak_in_function_DlgCreate8-5491.patch Requires: xdg-utils Requires: (autotrace or potrace) @@ -72,10 +74,7 @@ This package contains documentation files for %{name}. %prep -%setup -q -%patch -P 0 -p1 -%patch -P 1 -p1 -%patch -P 2 -p0 +%autosetup -p1 # Remove tests that requires Internet access sed -i '45d;82d;101d;127d' tests/CMakeLists.txt @@ -132,6 +131,12 @@ popd %doc %{_pkgdocdir} %changelog +* Tue Oct 28 2025 Parag Nemade - 20230101-16 +- Move to use %%autosetup macro so that we will not forget to apply patches + +* Mon Oct 27 2025 Parag Nemade - 20230101-15 +- Resolves: CVE-2025-50949 + * Wed Jul 17 2024 Fedora Release Engineering - 20230101-14 - Rebuilt for https://fedoraproject.org/wiki/Fedora_41_Mass_Rebuild diff --git a/pyconfig.patch b/pyconfig.patch index cfd90f4..628902e 100644 --- a/pyconfig.patch +++ b/pyconfig.patch @@ -1,5 +1,5 @@ ---- pycontrib/FontCompare/setup.py~ 2022-12-31 23:25:21.000000000 -0600 -+++ pycontrib/FontCompare/setup.py 2024-06-14 15:14:14.119920623 -0500 +--- fontforge/pycontrib/FontCompare/setup.py~ 2022-12-31 23:25:21.000000000 -0600 ++++ fontforge/pycontrib/FontCompare/setup.py 2024-06-14 15:14:14.119920623 -0500 @@ -15,7 +15,6 @@ along with this program. If not, see . """ @@ -8,8 +8,8 @@ from setuptools import setup setup(name='Font Compare', version='1.0', ---- fontforge/python.c~ 2022-12-31 23:25:21.000000000 -0600 -+++ fontforge/python.c 2024-06-14 15:38:41.397897757 -0500 +--- fontforge/fontforge/python.c~ 2022-12-31 23:25:21.000000000 -0600 ++++ fontforge/fontforge/python.c 2024-06-14 15:38:41.397897757 -0500 @@ -19633,7 +19633,10 @@ if ( saved_progname ) free(saved_progname);