summaryrefslogtreecommitdiff
path: root/extra/neverball/neverball-1.5.4-libpng.patch
blob: d7b224673186f9dc4af5af271b20c2c8d6f4393d (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
Index: neverball-1.5.4/share/base_image.c
===================================================================
--- neverball-1.5.4.orig/share/base_image.c
+++ neverball-1.5.4/share/base_image.c
@@ -15,6 +15,7 @@
 #include <png.h>
 #include <jpeglib.h>
 #include <stdlib.h>
+#include <string.h>
 #include <assert.h>
 
 #include "glext.h"
@@ -94,7 +95,7 @@ static void *image_load_png(const char *
         default: longjmp(png_jmpbuf(readp), -1);
         }
 
-        if (!(bytep = png_malloc(readp, h * png_sizeof(png_bytep))))
+        if (!(bytep = png_malloc(readp, h * sizeof(png_bytep))))
             longjmp(png_jmpbuf(readp), -1);
 
         /* Allocate the final pixel buffer and read pixels there. */