pkgsrc-WIP-changes archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

mupdf: Readd comment to patches/patch-source_fitz_load-jpx.c



Module Name:	pkgsrc-wip
Committed By:	Leonardo Taccari <leot%NetBSD.org@localhost>
Pushed By:	leot
Date:		Wed Sep 26 15:49:10 2018 +0200
Changeset:	463cc9bf372d8df71b18e2a8d2610c56ccabc2a5

Modified Files:
	mupdf/distinfo
	mupdf/patches/patch-source_fitz_load-jpx.c

Log Message:
mupdf: Readd comment to patches/patch-source_fitz_load-jpx.c

(It was accidently lost in the 1.14.0rc1 update.)

To see a diff of this commit:
https://wip.pkgsrc.org/cgi-bin/gitweb.cgi?p=pkgsrc-wip.git;a=commitdiff;h=463cc9bf372d8df71b18e2a8d2610c56ccabc2a5

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.

diffstat:
 mupdf/distinfo                             |  2 +-
 mupdf/patches/patch-source_fitz_load-jpx.c | 13 +++++++++++++
 2 files changed, 14 insertions(+), 1 deletion(-)

diffs:
diff --git a/mupdf/distinfo b/mupdf/distinfo
index 0f1cd8259e..5a6f140223 100644
--- a/mupdf/distinfo
+++ b/mupdf/distinfo
@@ -10,5 +10,5 @@ SHA1 (patch-ac) = c1f9fc9223f91dc2edcffcc1111de5103cd9a1bb
 SHA1 (patch-ae) = c6b113818b32cb4470e8549c00a16e0b2f364ede
 SHA1 (patch-platform_gl_gl-app.h) = f8682b54821a560b2ba1082bcf215eeefb549644
 SHA1 (patch-platform_gl_gl-main.c) = 8211423b2abdd1b1ce8af30da060f7d8e4c8fca0
-SHA1 (patch-source_fitz_load-jpx.c) = 81e83187c843f504d61f0b763aa5e53e9ccd47ed
+SHA1 (patch-source_fitz_load-jpx.c) = 161d21bca13bb57db37807aec844c85dc5b34157
 SHA1 (patch-thirdparty_mujs_Makefile) = fc7cbbbeb2a59c4322e2ed46e12cf3dddfd21d28
diff --git a/mupdf/patches/patch-source_fitz_load-jpx.c b/mupdf/patches/patch-source_fitz_load-jpx.c
index 8f64127908..c5967f971d 100644
--- a/mupdf/patches/patch-source_fitz_load-jpx.c
+++ b/mupdf/patches/patch-source_fitz_load-jpx.c
@@ -1,5 +1,18 @@
 $NetBSD$
 
+- MuPDF does some locking around its allocation calls; it overrides openjpeg's
+  allocators to do this locking too. However mupdf tries to manually align things
+  in a way that doesn't match what openjpeg does, which we noticed when frees
+  were segfaulting because the addresses didn't match up.
+
+  In the case of the openjpeg port it's relying on malloc(3)'s guarantee
+  "The allocated space is suitably aligned (after possible pointer coercion)
+  for storage of any type of object" so patch mupdf to do the same.
+
+  Fixes crash noticed by jca@ in https://www.broadband-forum.org/technical/download/TR-177.pdf
+
+  From OpenBSD ports textproc/mupdf/patch-source_fitz_load-jpx_c,v 1.5.
+
 --- source/fitz/load-jpx.c.orig	2018-09-25 12:39:17.000000000 +0000
 +++ source/fitz/load-jpx.c
 @@ -577,19 +577,7 @@ void opj_free(void *ptr)


Home | Main Index | Thread Index | Old Index