aboutsummaryrefslogtreecommitdiff
path: root/zlib/zutil.h
diff options
context:
space:
mode:
authorTom Tromey <tromey@redhat.com>2005-09-12 17:42:53 +0000
committerTom Tromey <tromey@gcc.gnu.org>2005-09-12 17:42:53 +0000
commitef3381664e516d137c80ebbf48c085220d5810ab (patch)
treeafad186af73219e6bb1a8cb8eac61485fb4eec97 /zlib/zutil.h
parent3ec980b182de950223663d4a3ef65177fa887501 (diff)
downloadgcc-ef3381664e516d137c80ebbf48c085220d5810ab.zip
gcc-ef3381664e516d137c80ebbf48c085220d5810ab.tar.gz
gcc-ef3381664e516d137c80ebbf48c085220d5810ab.tar.bz2
* Imported zlib 1.2.3; merged local changes.
From-SVN: r104184
Diffstat (limited to 'zlib/zutil.h')
-rw-r--r--zlib/zutil.h29
1 files changed, 20 insertions, 9 deletions
diff --git a/zlib/zutil.h b/zlib/zutil.h
index 65d4bd7..3880b08 100644
--- a/zlib/zutil.h
+++ b/zlib/zutil.h
@@ -1,5 +1,5 @@
/* zutil.h -- internal interface and configuration of the compression library
- * Copyright (C) 1995-2003 Jean-loup Gailly.
+ * Copyright (C) 1995-2005 Jean-loup Gailly.
* For conditions of distribution and use, see copyright notice in zlib.h
*/
@@ -17,14 +17,26 @@
#include "zlib.h"
#ifdef STDC
-# include <stddef.h>
+# ifndef _WIN32_WCE
+# include <stddef.h>
+# endif
# include <string.h>
# include <stdlib.h>
#endif
#ifdef NO_ERRNO_H
+# ifdef _WIN32_WCE
+ /* The Microsoft C Run-Time Library for Windows CE doesn't have
+ * errno. We define it as a global variable to simplify porting.
+ * Its value is always 0 and should not be used. We rename it to
+ * avoid conflict with other libraries that use the same workaround.
+ */
+# define errno z_errno
+# endif
extern int errno;
#else
-# include <errno.h>
+# ifndef _WIN32_WCE
+# include <errno.h>
+# endif
#endif
#ifndef local
@@ -105,6 +117,9 @@ extern const char * const z_errmsg[10]; /* indexed by 2-zlib_error */
#ifdef OS2
# define OS_CODE 0x06
+# ifdef M_I86
+ #include <malloc.h>
+# endif
#endif
#if defined(MACOS) || defined(TARGET_OS_MAC)
@@ -189,12 +204,8 @@ extern const char * const z_errmsg[10]; /* indexed by 2-zlib_error */
# define NO_vsnprintf
# endif
#endif
-
-#ifdef HAVE_STRERROR
- extern char *strerror OF((int));
-# define zstrerror(errnum) strerror(errnum)
-#else
-# define zstrerror(errnum) ""
+#ifdef VMS
+# define NO_vsnprintf
#endif
#if defined(pyr)