From 24b3587d4154fcdccfa2f125a5e9a1b4a3febae0 Mon Sep 17 00:00:00 2001 From: Jindrich Novy Date: Wed, 28 Jan 2009 18:25:26 +0000 Subject: [PATCH] - fix segfault in ximtoppm (#482891), the utility lacked the command line parsing initialization code --- netpbm-10.35-ximtoppmsegfault.patch | 14 ++++++++++++++ netpbm.spec | 8 +++++++- 2 files changed, 21 insertions(+), 1 deletion(-) create mode 100644 netpbm-10.35-ximtoppmsegfault.patch diff --git a/netpbm-10.35-ximtoppmsegfault.patch b/netpbm-10.35-ximtoppmsegfault.patch new file mode 100644 index 0000000..cee6fd6 --- /dev/null +++ b/netpbm-10.35-ximtoppmsegfault.patch @@ -0,0 +1,14 @@ +diff -up netpbm-10.35.58/converter/ppm/ximtoppm.c.ximtoppmsegfault netpbm-10.35.58/converter/ppm/ximtoppm.c +--- netpbm-10.35.58/converter/ppm/ximtoppm.c.ximtoppmsegfault 2009-01-28 18:37:05.000000000 +0100 ++++ netpbm-10.35.58/converter/ppm/ximtoppm.c 2009-01-28 19:01:14.000000000 +0100 +@@ -50,6 +50,10 @@ parseCommandLine(int argc, char ** argv, + OPTENT3(0, "alphaout", OPT_STRING, + &cmdlineP->alpha_filename, &alphaoutSpec, 0); + ++ opt.opt_table = option_def; ++ opt.short_allowed = FALSE; ++ opt.allowNegNum = FALSE; ++ + optParseOptions3(&argc, argv, opt, sizeof(opt), 0); + /* Uses and sets argc, argv, and all of *cmdlineP. */ + diff --git a/netpbm.spec b/netpbm.spec index 3d1f667..f9dc33a 100644 --- a/netpbm.spec +++ b/netpbm.spec @@ -1,7 +1,7 @@ Summary: A library for handling different graphics file formats Name: netpbm Version: 10.35.58 -Release: 3%{?dist} +Release: 4%{?dist} # See copyright_summary for details License: BSD and GPLv2 and IJG and MIT and Public Domain Group: System Environment/Libraries @@ -34,6 +34,7 @@ Patch21: netpbm-10.35-pamtosvgsegfault.patch Patch22: netpbm-10.35-pnmmontagefix.patch Patch23: netpbm-10.35-pnmtofiasco-stdin.patch Patch24: netpbm-10.35-64bitfix.patch +Patch25: netpbm-10.35-ximtoppmsegfault.patch Buildroot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n) BuildRequires: libjpeg-devel, libpng-devel, libtiff-devel, flex BuildRequires: libX11-devel, python, jasper-devel @@ -98,6 +99,7 @@ netpbm-progs. You'll also need to install the netpbm package. %patch22 -p1 -b .pnmmontagefix %patch23 -p1 -b .pnmtofiasco-stdin %patch24 -p1 -b .64bitfix +%patch25 -p1 -b .ximtoppmsegfault ##mv shhopt/shhopt.h shhopt/pbmshhopt.h ##perl -pi -e 's|shhopt.h|pbmshhopt.h|g' `find -name "*.c" -o -name "*.h"` ./GNUmakefile @@ -225,6 +227,10 @@ rm -rf $RPM_BUILD_ROOT %{_datadir}/netpbm/ %changelog +* Wed Jan 28 2009 Jindrich Novy 10.35.58-4 +- fix segfault in ximtoppm (#482891), the utility lacked the + command line parsing initialization code + * Thu Jan 22 2009 Jindrich Novy 10.35.58-3 - fix cmuwmtopbm and other utilities by making endianess functions work correctly on 64bit systems (#476863)