]> granicus.if.org Git - libjpeg-turbo/commitdiff
Fix MinGW build and remove duplication of effort
authorDRC <dcommander@users.sourceforge.net>
Tue, 2 Oct 2012 06:47:37 +0000 (06:47 +0000)
committerDRC <dcommander@users.sourceforge.net>
Tue, 2 Oct 2012 06:47:37 +0000 (06:47 +0000)
git-svn-id: svn+ssh://svn.code.sf.net/p/libjpeg-turbo/code/trunk@864 632fc199-4ca6-4c93-a231-07263d6284db

turbojpeg-jni.c

index d570ee9ba38a96ed37bf84fab0207dd706222fed..96a4a685a1a75551855fa918fe7941de7715e5cb 100644 (file)
@@ -29,6 +29,9 @@
 #include <stdlib.h>
 #include <string.h>
 #include "turbojpeg.h"
+#ifdef WIN32
+#include "tjutil.h"
+#endif
 #include <jni.h>
 #include "java/org_libjpegturbo_turbojpeg_TJCompressor.h"
 #include "java/org_libjpegturbo_turbojpeg_TJDecompressor.h"
        goto bailout;  \
 }
 
-#ifdef WIN32
-#define snprintf(str, n, format, ...)  \
-       _snprintf_s(str, n, _TRUNCATE, format, __VA_ARGS__)
-#endif
-
 #define bailif0(f) {if(!(f)) {  \
        char temps[80];  \
        snprintf(temps, 80, "Unexpected NULL condition in line %d", __LINE__);  \