]> git.rm.cloudns.org Git - xonotic/darkplaces.git/commitdiff
fix jump buffer type
authordivverent <divverent@d7cf8633-e32d-0410-b094-e92efae38249>
Sun, 12 Feb 2012 08:14:26 +0000 (08:14 +0000)
committerRudolf Polzer <divverent@alientrap.org>
Sun, 12 Feb 2012 08:46:40 +0000 (09:46 +0100)
git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@11682 d7cf8633-e32d-0410-b094-e92efae38249
::stable-branch::merge=50c0fce741481cf340d6bb2d3224210c120220a8

image_png.c

index e498b9e5f2743aa34c83932bc390ed126e444bf3..3965a50e1ca8ea6fdb5299943ed70838438c34d3 100644 (file)
 #include "image.h"
 #include "image_png.h"
 
+/*
+#ifdef __cplusplus
+#ifdef WIN64
+typedef _JBTYPE *qpng_jmpbuf_t;
+#elif defined(MACOSX) || defined(WIN32)
+typedef int *qpng_jmpbuf_t;
+#else
+typedef __jmp_buf_tag *qpng_jmpbuf_t;
+#endif
+#else
+typedef void *qpng_jmpbuf_t;
+#endif
+*/
+typedef jmp_buf qpng_jmpbuf_t;
+
 static void                            (*qpng_set_sig_bytes)           (void*, int);
 static int                             (*qpng_sig_cmp)                         (const unsigned char*, size_t, size_t);
 static void*                   (*qpng_create_read_struct)      (const char*, void*, void(*)(void *png, const char *message), void(*)(void *png, const char *message));
@@ -63,7 +78,7 @@ static unsigned int                   (*qpng_access_version_number)           (void); // FIXME is this re
 static void                            (*qpng_write_info)                      (void*, void*);
 static void                            (*qpng_write_row)                       (void*, unsigned char*);
 static void                            (*qpng_write_end)                       (void*, void*);
-static void*                           (*qpng_jmpbuf)          (void*);
+static qpng_jmpbuf_t                   (*qpng_jmpbuf)          (void*);
 
 static dllfunction_t pngfuncs[] =
 {