[pbm2l2030] fix static array overrun (#729690)
Jiří Popelka
jpopelka at fedoraproject.org
Thu Oct 4 14:43:04 UTC 2012
commit 9c22b33a82e4d5bb6d4f800a464a68501c8a40ca
Author: Jiri Popelka <jpopelka at redhat.com>
Date: Thu Oct 4 16:42:15 2012 +0200
fix static array overrun (#729690)
pbm2l2030-overrun-static.patch | 12 ++++++++++++
pbm2l2030.spec | 23 +++++++++--------------
2 files changed, 21 insertions(+), 14 deletions(-)
---
diff --git a/pbm2l2030-overrun-static.patch b/pbm2l2030-overrun-static.patch
new file mode 100644
index 0000000..50b7c01
--- /dev/null
+++ b/pbm2l2030-overrun-static.patch
@@ -0,0 +1,12 @@
+diff -up pbm2l2030-1.4/pbm2l2030.c.overrun-static pbm2l2030-1.4/pbm2l2030.c
+--- pbm2l2030-1.4/pbm2l2030.c.overrun-static 2011-08-10 15:25:19.719394490 +0100
++++ pbm2l2030-1.4/pbm2l2030.c 2011-08-10 15:25:48.460879691 +0100
+@@ -82,7 +82,7 @@ void lex_eop(FILE *out)
+ {
+ int i;
+ char buffer[] = {0x1B,0x2A,0x07,0x65};
+- for(i=0; i<=12; i++) fprintf(out, "%c", buffer[i]);
++ for(i=0; i<=3; i++) fprintf(out, "%c", buffer[i]);
+ }
+
+ /***************************************************************************
diff --git a/pbm2l2030.spec b/pbm2l2030.spec
index 50c5898..411f41c 100644
--- a/pbm2l2030.spec
+++ b/pbm2l2030.spec
@@ -1,18 +1,13 @@
Name: pbm2l2030
Version: 1.4
-Release: 8%{?dist}
+Release: 9%{?dist}
Summary: Converts PBM stream to Lexmark 2030 printer language
Group: System Environment/Libraries
License: GPLv2+
-# This is the original one, but has gone away...
-#URL: http://home.t-online.de/home/paetzold-net/page_004.html
-# ...and as the original upstream author did not respond to e-mails,
-# here is at least some reference:
-URL: http://www.linuxprinting.org/show_driver.cgi?driver=%{name}
-Source0: %{name}-%{version}.tar.gz
-
-BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
+URL: http://www.openprinting.org/driver/pbm2l2030
+Source0: pbm2l2030-%{version}.tar.gz
+Patch1: pbm2l2030-overrun-static.patch
%description
This is a filter to convert pbmraw data such as produced by ghostscript to
@@ -21,25 +16,25 @@ by the PostScript Description files of the drivers from the foomatic package.
%prep
%setup -q
+# BZ#729690
+%patch1 -p1 -b .overrun-static
%build
# The included Makefile is badly written
%{__cc} %{optflags} -o pbm2l2030 pbm2l2030.c pbm.c
%install
-rm -rf $RPM_BUILD_ROOT
%{__mkdir} -p $RPM_BUILD_ROOT/%{_bindir}
%{__install} pbm2l2030 $RPM_BUILD_ROOT/%{_bindir}
-%clean
-rm -rf $RPM_BUILD_ROOT
-
%files
-%defattr(-,root,root,-)
%{_bindir}/pbm2l2030
%doc LICENSE README.TXT
%changelog
+* Thu Oct 04 2012 Jiri Popelka <jpopelka at redhat.com> 1.4-9
+- fix static array overrun (#729690)
+
* Fri Jul 20 2012 Fedora Release Engineering <rel-eng at lists.fedoraproject.org> - 1.4-8
- Rebuilt for https://fedoraproject.org/wiki/Fedora_18_Mass_Rebuild
More information about the scm-commits
mailing list