summaryrefslogtreecommitdiff
path: root/lang/ofc/files/patch-ofc_DPNGImage.m
diff options
context:
space:
mode:
authorBaptiste Daroussin <bapt@FreeBSD.org>2014-12-25 10:49:46 +0000
committerBaptiste Daroussin <bapt@FreeBSD.org>2014-12-25 10:49:46 +0000
commitce1be232cfcdc92b6800ea5fad152714b07c0829 (patch)
treeaac9981ae5acbb1d501e565d3a355f36cc6856a7 /lang/ofc/files/patch-ofc_DPNGImage.m
parentProperly support png 1.5 (diff)
Properly support png 1.5
Diffstat (limited to 'lang/ofc/files/patch-ofc_DPNGImage.m')
-rw-r--r--lang/ofc/files/patch-ofc_DPNGImage.m47
1 files changed, 47 insertions, 0 deletions
diff --git a/lang/ofc/files/patch-ofc_DPNGImage.m b/lang/ofc/files/patch-ofc_DPNGImage.m
new file mode 100644
index 000000000000..c7844c774eed
--- /dev/null
+++ b/lang/ofc/files/patch-ofc_DPNGImage.m
@@ -0,0 +1,47 @@
+--- ofc/DPNGImage.m.orig 2008-08-20 17:16:29 UTC
++++ ofc/DPNGImage.m
+@@ -346,7 +346,7 @@ static void _warning(png_structp png, pn
+
+ if (ok)
+ {
+- if (setjmp(png->jmpbuf))
++ if (setjmp(png_jmpbuf(png)))
+ {
+ WARNING(DW_UNKNOWN_WARNING, "Error reading PNG file");
+ ok = NO;
+@@ -406,7 +406,7 @@ static void _warning(png_structp png, pn
+
+ _width = (unsigned) width;
+ _height = (unsigned) height;
+- _bpp = info->channels;
++ _bpp = png_get_channels(png, info);
+ _images = 1;
+
+ _reading = YES;
+@@ -485,7 +485,7 @@ static void _warning(png_structp png, pn
+
+ if (ok)
+ {
+- if (setjmp(png->jmpbuf))
++ if (setjmp(png_jmpbuf(png)))
+ {
+ WARNING(DW_UNKNOWN_WARNING, "Error writing PNG file");
+ ok = NO;
+@@ -553,7 +553,7 @@ static void _warning(png_structp png, pn
+
+ pixels = _width;
+
+- if (setjmp(png->jmpbuf))
++ if (setjmp(png_jmpbuf(png)))
+ {
+ WARNING(DW_UNKNOWN_WARNING, "Error reading PNG file");
+ pixels = 0;
+@@ -599,7 +599,7 @@ static void _warning(png_structp png, pn
+
+ png_structp png = (png_structp) _png;
+
+- if (setjmp(png->jmpbuf))
++ if (setjmp(png_jmpbuf(png)))
+ {
+ WARNING(DW_UNKNOWN_WARNING, "Error writing PNG file");
+ ok = NO;