From 38742e9f216ab5e888ae8c9a8a07be488bcb7dc5 Mon Sep 17 00:00:00 2001 From: CentOS Sources Date: May 20 2020 14:57:58 +0000 Subject: import libpaper-1.1.24-9.el7 --- diff --git a/SOURCES/libpaper-file-leak.patch b/SOURCES/libpaper-file-leak.patch new file mode 100644 index 0000000..47b878b --- /dev/null +++ b/SOURCES/libpaper-file-leak.patch @@ -0,0 +1,22 @@ +diff -up libpaper-1.1.24+nmu5/lib/paper.c.file-leak libpaper-1.1.24+nmu5/lib/paper.c +--- libpaper-1.1.24+nmu5/lib/paper.c.file-leak 2018-03-09 16:21:01.028345956 +0100 ++++ libpaper-1.1.24+nmu5/lib/paper.c 2018-03-09 16:40:57.824279357 +0100 +@@ -140,7 +140,7 @@ char* systempapername(void) { + char* paperstr; + char* paperenv; + const char* paperdef; +- FILE* ps; ++ FILE* ps = NULL; + struct stat statbuf; + const struct paper* pp; + int c; +@@ -224,6 +224,9 @@ PAPERSIZEVAR, fall-back to the old behav + } + } + ++ if (ps) ++ fclose(ps); ++ + paperdef = defaultpapername(); + paperstr = malloc((strlen(paperdef) + 1) * sizeof(char)); + diff --git a/SPECS/libpaper.spec b/SPECS/libpaper.spec index 3c36ebd..2c900bf 100644 --- a/SPECS/libpaper.spec +++ b/SPECS/libpaper.spec @@ -2,7 +2,7 @@ Name: libpaper Version: 1.1.24 -Release: 8%{?dist} +Release: 9%{?dist} Summary: Library and tools for handling papersize Group: System Environment/Libraries License: GPLv2 @@ -17,6 +17,9 @@ Patch1: libpaper-1.1.23-debianbug475683.patch # Filed upstream as: # http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=481213 Patch2: libpaper-useglibcfallback.patch +# 1753534 - Too many open files in ImageMagick +Patch3: libpaper-file-leak.patch + BuildRequires: libtool, gettext, gawk %description @@ -41,6 +44,7 @@ to develop applications which use libpaper. %patch0 -p1 -b .automake110 %patch1 -p1 -b .dlfix %patch2 -p1 -b .useglibcfallback +%patch3 -p1 -b .file-leak libtoolize %build @@ -87,6 +91,9 @@ done %{_mandir}/man3/* %changelog +* Wed Jan 29 2020 Zdenek Dohnal - 1.1.24-9 +- 1753534 - Too many open files in ImageMagick + * Fri Jan 24 2014 Daniel Mach - 1.1.24-8 - Mass rebuild 2014-01-24