summaryrefslogtreecommitdiff
path: root/gzwrite.c
diff options
context:
space:
mode:
authorMark Adler <madler@alumni.caltech.edu>2012-02-01 23:25:34 -0800
committerMark Adler <madler@alumni.caltech.edu>2012-02-01 23:25:34 -0800
commit55b8b5fec16503cb9ce26074f600a1d7b426a0cc (patch)
tree7e14662a33ffd8141e9a794329aa0a731250f486 /gzwrite.c
parenta8d23bb675e05cfc0cc70ddc8ea03dbbf0e49fb8 (diff)
downloadzlib-55b8b5fec16503cb9ce26074f600a1d7b426a0cc.tar.gz
Put gzflags() functionality back in zutil.c.
gzflags() was put in gzwrite.c in order to be compiled exactly the same as gzprintf(), so that it was guaranteed to return the correct information. However that causes a static linkage to zlib to bring in many routines that are often not used. All that is required to duplicate the compilation environment of gzprintf() is to include gzguts.h. So that is now done in zutil.c to assure that the correct flags are returned.
Diffstat (limited to 'gzwrite.c')
-rw-r--r--gzwrite.c31
1 files changed, 0 insertions, 31 deletions
diff --git a/gzwrite.c b/gzwrite.c
index caa35b6..3b24b84 100644
--- a/gzwrite.c
+++ b/gzwrite.c
@@ -560,34 +560,3 @@ int ZEXPORT gzclose_w(file)
free(state);
return ret;
}
-
-/* used by zlibVersion() to get the vsnprintf story from the horse's mouth */
-unsigned long ZEXPORT gzflags()
-{
- unsigned long flags = 0;
-#if defined(STDC) || defined(Z_HAVE_STDARG_H)
-# ifdef NO_vsnprintf
- flags += 1L << 25;
-# ifdef HAS_vsprintf_void
- flags += 1L << 26;
-# endif
-# else
-# ifdef HAS_vsnprintf_void
- flags += 1L << 26;
-# endif
-# endif
-#else
- flags += 1L << 24;
-# ifdef NO_snprintf
- flags += 1L << 25;
-# ifdef HAS_sprintf_void
- flags += 1L << 26;
-# endif
-# else
-# ifdef HAS_snprintf_void
- flags += 1L << 26;
-# endif
-# endif
-#endif
- return flags;
-}