From e5f8b475ed313bf500514327c2b963902c6980cf Mon Sep 17 00:00:00 2001 From: Scott McCreary Date: Tue, 5 Nov 2013 06:07:58 +0000 Subject: [PATCH] Moved z_streamp up to top of block so it builds with GCC2, and include zlib.h on Haiku --- src/tuxpaint.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/tuxpaint.c b/src/tuxpaint.c index dc1e8f79b..2522ab6d3 100644 --- a/src/tuxpaint.c +++ b/src/tuxpaint.c @@ -232,6 +232,7 @@ char *strcasestr(const char *haystack, const char *needle) #include #ifdef __HAIKU__ +#include #include #include #include @@ -20937,6 +20938,8 @@ Bytef *get_chunk_data(FILE * fp, char *fname, png_structp png_ptr, int f, count, comp, unc_err; char *control, *softwr; Bytef *comp_buff, *unc_buff; + + z_streamp zstp; control = malloc(50); softwr = malloc(50); @@ -20992,7 +20995,6 @@ Bytef *get_chunk_data(FILE * fp, char *fname, png_structp png_ptr, /* Seems that uncompress() has problems in 64bits systems, so using inflate() Pere 2012/03/28 */ /* unc_err = uncompress(unc_buff, (uLongf *) unc_size, comp_buff, comp); */ - z_streamp zstp; zstp = malloc(sizeof(z_stream)); zstp->next_in = comp_buff; zstp->avail_in = comp;