]> git.lizzy.rs Git - zlib.git/blobdiff - zconf.h
Use snprintf() for later versions of Microsoft C.
[zlib.git] / zconf.h
diff --git a/zconf.h b/zconf.h
index c6ec884d10c226f923ab1830d5acd69bcf7d5997..ca12b79232bb6ada8a1aeeb06697afa3d501033e 100644 (file)
--- a/zconf.h
+++ b/zconf.h
@@ -1,5 +1,5 @@
 /* zconf.h -- configuration of the zlib compression library
- * Copyright (C) 1995-2012 Jean-loup Gailly.
+ * Copyright (C) 1995-2013 Jean-loup Gailly.
  * For conditions of distribution and use, see copyright notice in zlib.h
  */
 
@@ -78,6 +78,7 @@
 #      define gzopen_w              z_gzopen_w
 #    endif
 #    define gzprintf              z_gzprintf
+#    define gzvprintf             z_gzvprintf
 #    define gzputc                z_gzputc
 #    define gzputs                z_gzputs
 #    define gzread                z_gzread
 #  define z_const
 #endif
 
-/* Some Mac compilers merge all .h files incorrectly: */
-#if defined(__MWERKS__)||defined(applec)||defined(THINK_C)||defined(__SC__)
-#  define NO_DUMMY_DECL
+#ifndef Z_SOLO
+#  define z_longlong long long
+#  ifdef NO_SIZE_T
+     typedef unsigned NO_SIZE_T z_size_t;
+#  else
+#    include <stddef.h>
+     typedef size_t z_size_t;
+#  endif
+#  ifdef NO_SSIZE_T
+     typedef NO_SSIZE_T z_ssize_t;
+#  else
+#    include <sys/types.h>
+     typedef ssize_t z_ssize_t;
+#  endif
+#  undef z_longlong
 #endif
 
 /* Maximum value for memLevel in deflateInit2 */
  Of course this will generally degrade compression (there's no free lunch).
 
    The memory requirements for inflate are (in bytes) 1 << windowBits
- that is, 32K for windowBits=15 (default value) plus a few kilobytes
+ that is, 32K for windowBits=15 (default value) plus about 7 kilobytes
  for small objects.
 */
 
@@ -392,11 +405,11 @@ typedef uLong FAR uLongf;
 
 #if !defined(Z_U4) && !defined(Z_SOLO) && defined(STDC)
 #  include <limits.h>
-#  if (UINT_MAX == 4294967295)
+#  if (UINT_MAX == 0xffffffffUL)
 #    define Z_U4 unsigned
-#  elif (ULONG_MAX == 4294967295)
+#  elif (ULONG_MAX == 0xffffffffUL)
 #    define Z_U4 unsigned long
-#  elif (USHRT_MAX == 4294967295)
+#  elif (USHRT_MAX == 0xffffffffUL)
 #    define Z_U4 unsigned short
 #  endif
 #endif