From 7850e4e406dce1f7a819297eeb151d1ca18e7cd9 Mon Sep 17 00:00:00 2001 From: Mark Adler Date: Fri, 9 Sep 2011 23:17:33 -0700 Subject: zlib 1.0.7 --- zutil.c | 22 +++++++++++++++++++--- 1 file changed, 19 insertions(+), 3 deletions(-) (limited to 'zutil.c') diff --git a/zutil.c b/zutil.c index 734e275..84b7ee1 100644 --- a/zutil.c +++ b/zutil.c @@ -1,9 +1,9 @@ /* zutil.c -- target dependent utility functions for the compression library - * Copyright (C) 1995-1996 Jean-loup Gailly. + * Copyright (C) 1995-1998 Jean-loup Gailly. * For conditions of distribution and use, see copyright notice in zlib.h */ -/* $Id: zutil.c,v 1.17 1996/07/24 13:41:12 me Exp $ */ +/* @(#) $Id$ */ #include @@ -28,12 +28,18 @@ const char *z_errmsg[10] = { ""}; -const char *zlibVersion() +const char * EXPORT zlibVersion() { return ZLIB_VERSION; } #ifdef DEBUG + +# ifndef verbose +# define verbose 0 +# endif +int z_verbose = verbose; + void z_error (m) char *m; { @@ -42,6 +48,16 @@ void z_error (m) } #endif +/* exported to allow conversion of error code to string for compress() and + * uncompress() + */ +const char * EXPORT zError(err) + int err; +{ + return ERR_MSG(err); +} + + #ifndef HAVE_MEMCPY void zmemcpy(dest, source, len) -- cgit v1.2.3-55-g6feb