app-text/mupdf: fix format-security (bug 556830).
authorMichael Weber <xmw@gentoo.org>
Mon, 10 Aug 2015 22:52:28 +0000 (00:52 +0200)
committerMichael Weber <xmw@gentoo.org>
Mon, 10 Aug 2015 22:52:45 +0000 (00:52 +0200)
Package-Manager: portage-2.2.20

app-text/mupdf/files/mupdf-1.5-format-security-error.patch [new file with mode: 0644]
app-text/mupdf/mupdf-1.5-r1.ebuild

diff --git a/app-text/mupdf/files/mupdf-1.5-format-security-error.patch b/app-text/mupdf/files/mupdf-1.5-format-security-error.patch
new file mode 100644 (file)
index 0000000..d0dce97
--- /dev/null
@@ -0,0 +1,22 @@
+From: =?utf-8?q?=22Kan-Ru_Chen_=28=E9=99=B3=E4=BE=83=E5=A6=82=29=22?=
+ <koster@debian.org>
+Date: Sat, 20 Sep 2014 13:12:16 +0800
+Subject: Fix -Werror=format-security error
+
+---
+ source/pdf/pdf-op-run.c | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/source/pdf/pdf-op-run.c b/source/pdf/pdf-op-run.c
+index 2bea94b..da881b2 100644
+--- a/source/pdf/pdf-op-run.c
++++ b/source/pdf/pdf-op-run.c
+@@ -1729,7 +1729,7 @@ run_xobject(pdf_csi *csi, void *state, pdf_obj *resources, pdf_xobject *xobj, co
+       /* Rethrow postponed errors */
+       if (errmess[0])
+-              fz_throw(ctx, FZ_ERROR_GENERIC, errmess);
++              fz_throw(ctx, FZ_ERROR_GENERIC, "%s", errmess);
+ }
+ static void pdf_run_BDC(pdf_csi *csi, void *state)
index 791a17d9d5fc09d115fcd1b2db4e7a66dab2fb62..b066b49e2844ecb8f85310b14d0ad99f5b55db07 100644 (file)
@@ -41,7 +41,8 @@ src_prepare() {
                "${FILESDIR}"/${PN}-1.3-CFLAGS.patch \
                "${FILESDIR}"/${PN}-1.5-old-debian-files.patch \
                "${FILESDIR}"/${PN}-1.3-pkg-config.patch \
-               "${FILESDIR}"/${PN}-1.5-Makerules-openssl-curl.patch
+               "${FILESDIR}"/${PN}-1.5-Makerules-openssl-curl.patch \
+               "${FILESDIR}"/${PN}-1.5-format-security-error.patch
 
        if has_version ">=media-libs/openjpeg-2.1:2" ; then
                epatch \