[ghostscript/f19] Use upstream patch to fix gs segfault (bug #1036428).
Tim Waugh
twaugh at fedoraproject.org
Tue Dec 10 16:53:25 UTC 2013
commit 80985fa14c1f0214a3ed2ef9e88c85116142e702
Author: Tim Waugh <twaugh at redhat.com>
Date: Tue Dec 10 16:12:20 2013 +0000
Use upstream patch to fix gs segfault (bug #1036428).
Resolves: rhbz#1036428
ghostscript-gs694154.patch | 24 ++++++++++++++++++++++++
ghostscript.spec | 9 ++++++++-
2 files changed, 32 insertions(+), 1 deletions(-)
---
diff --git a/ghostscript-gs694154.patch b/ghostscript-gs694154.patch
new file mode 100644
index 0000000..5ecf701
--- /dev/null
+++ b/ghostscript-gs694154.patch
@@ -0,0 +1,24 @@
+diff -up ghostscript-9.10/base/gsicc.c.gs694154 ghostscript-9.10/base/gsicc.c
+--- ghostscript-9.10/base/gsicc.c.gs694154 2013-08-30 11:37:28.000000000 +0100
++++ ghostscript-9.10/base/gsicc.c 2013-12-10 16:06:58.364001185 +0000
+@@ -354,6 +354,8 @@ gx_remap_ICC(const gs_client_color * pcc
+ cmm_dev_profile_t *dev_profile;
+
+ code = dev_proc(dev, get_profile)(dev, &dev_profile);
++ if (dev_profile == NULL)
++ return gs_throw(gs_error_Fatal, "Attempting to do ICC remap with no profile");
+ num_des_comps = gsicc_get_device_profile_comps(dev_profile);
+ rendering_params.black_point_comp = pis->blackptcomp;
+ rendering_params.graphics_type_tag = dev->graphics_type_tag;
+diff -up ghostscript-9.10/base/gsstate.c.gs694154 ghostscript-9.10/base/gsstate.c
+--- ghostscript-9.10/base/gsstate.c.gs694154 2013-08-30 11:37:28.000000000 +0100
++++ ghostscript-9.10/base/gsstate.c 2013-12-10 16:06:58.364001185 +0000
+@@ -708,7 +708,7 @@ gs_setoverprint(gs_state * pgs, bool ovp
+ } else {
+ dev_proc(dev, get_profile)(dev, &profile_struct);
+ }
+- if (profile_struct->sim_overprint == false) return;
++ if (profile_struct != NULL && profile_struct->sim_overprint == false) return;
+ }
+ pgs->overprint = ovp;
+ if (prior_ovp != ovp)
diff --git a/ghostscript.spec b/ghostscript.spec
index 55ddff0..576e860 100644
--- a/ghostscript.spec
+++ b/ghostscript.spec
@@ -5,7 +5,7 @@ Summary: A PostScript interpreter and renderer
Name: ghostscript
Version: %{gs_ver}
-Release: 4%{?dist}
+Release: 5%{?dist}
# Included CMap data is Redistributable, no modification permitted,
# see http://bugzilla.redhat.com/487510
@@ -30,6 +30,7 @@ Patch6: ghostscript-Fontmap.local.patch
Patch7: ghostscript-iccprofiles-initdir.patch
Patch8: ghostscript-gdevcups-debug-uninit.patch
Patch9: ghostscript-wrf-snprintf.patch
+Patch10: ghostscript-gs694154.patch
Requires: urw-fonts >= 1.1, ghostscript-fonts
Requires: poppler-data
@@ -130,6 +131,9 @@ rm -rf expat freetype icclib jasper jpeg jpegxr lcms lcms2 libpng openjpeg zlib
# Use more caution when converting floats to strings (bug #980085).
%patch9 -p1 -b .wrf-snprintf
+# Use upstream patch to fix gs segfault (bug #1036428).
+%patch10 -p1 -b .gs694154
+
# Convert manual pages to UTF-8
from8859_1() {
iconv -f iso-8859-1 -t utf-8 < "$1" > "${1}_"
@@ -320,6 +324,9 @@ rm -rf $RPM_BUILD_ROOT
%{_libdir}/libgs.so
%changelog
+* Tue Dec 10 2013 Tim Waugh <twaugh at redhat.com> 9.10-5
+- Use upstream patch to fix gs segfault (bug #1036428).
+
* Wed Sep 25 2013 Tim Waugh <twaugh at redhat.com> 9.09-4
- Regenerate tarball (bug #1000387).
More information about the scm-commits
mailing list