summaryrefslogtreecommitdiff
path: root/x11/xcb-util-image
diff options
context:
space:
mode:
authormarino <marino@pkgsrc.org>2012-08-18 08:04:25 +0000
committermarino <marino@pkgsrc.org>2012-08-18 08:04:25 +0000
commit755ade239c1783107099a620a2b2c650230f0336 (patch)
treeee4e2090ff173298cf7bed8bd5c4f9a24f95d34e /x11/xcb-util-image
parentaf45c117c42ebb156ab2ceecba0eac63bb92447b (diff)
downloadpkgsrc-755ade239c1783107099a620a2b2c650230f0336.tar.gz
x11/xcb-util-image: Fix build for some compilers.
gcc44 complains "control reaches end of non-void function" on DragonFly Apparently gcc45+ recognizes the assert, but for those compilers that don't, putting a dummy return value won't hurt anything and it fixes the build at least for gcc 4.4.
Diffstat (limited to 'x11/xcb-util-image')
-rw-r--r--x11/xcb-util-image/distinfo3
-rw-r--r--x11/xcb-util-image/patches/patch-image_xcb__image.c26
2 files changed, 28 insertions, 1 deletions
diff --git a/x11/xcb-util-image/distinfo b/x11/xcb-util-image/distinfo
index 041b23f524a..593c79c90fa 100644
--- a/x11/xcb-util-image/distinfo
+++ b/x11/xcb-util-image/distinfo
@@ -1,5 +1,6 @@
-$NetBSD: distinfo,v 1.1 2012/08/12 21:19:06 wiz Exp $
+$NetBSD: distinfo,v 1.2 2012/08/18 08:04:25 marino Exp $
SHA1 (xcb-util-image-0.3.9.tar.bz2) = afeba6230400fe8bec6076fd07bf20a8e412bbb5
RMD160 (xcb-util-image-0.3.9.tar.bz2) = c666b87e20eaa703697df758e1d0e26aec2d62a4
Size (xcb-util-image-0.3.9.tar.bz2) = 310947 bytes
+SHA1 (patch-image_xcb__image.c) = d0a956fc8786f03c8cce9d87f748cc02d3a8ac21
diff --git a/x11/xcb-util-image/patches/patch-image_xcb__image.c b/x11/xcb-util-image/patches/patch-image_xcb__image.c
new file mode 100644
index 00000000000..5cbef864462
--- /dev/null
+++ b/x11/xcb-util-image/patches/patch-image_xcb__image.c
@@ -0,0 +1,26 @@
+$NetBSD: patch-image_xcb__image.c,v 1.1 2012/08/18 08:04:25 marino Exp $
+
+gcc44 complains "control reaches end of non-void function" on DragonFly
+Apparently gcc45+ recognizes the assert, but for those compilers that don't,
+putting a dummy return value won't hurt anything.
+
+--- image/xcb_image.c.orig 2011-06-30 08:05:22.000000000 +0000
++++ image/xcb_image.c
+@@ -187,6 +187,8 @@ xcb_image_create_native (xcb_connection_
+ assert(0);
+ }
+ assert(0);
++/* gcc44 complains "control reaches end of non-void function", fix below */
++ return (-1);
+ }
+
+
+@@ -750,6 +752,8 @@ xcb_image_get_pixel (xcb_image_t *image,
+ return pixel;
+ default:
+ assert(0);
++/* gcc44 complains "control reaches end of non-void function", fix below */
++ return (-1);
+ }
+ }
+