/*
 * zutil.c -- target dependent utility functions for the compression library
 * Copyright (C) 1995-1998 Jean-loup Gailly.
 * For conditions of distribution and use, see copyright notice in zlib.h 
 *
 * Note !
 * This version of zutil.c was modified.
 */

/* @(#) $Id$ */

#include "zutil.h"
#include "../../include/v_lib.h"

/*
 * exported to allow conversion of error code to string for compress()
 * and uncompress()
 */
const char * ZEXPORT zError(int err)
{
	conlPrintf(LOG_ERROR,"zLib error (%i).\n",err);
}

voidpf z_calloc(voidpf opaque, unsigned items, unsigned size)
{
	unsigned sz = items * size;
	voidpf ptr = memAlloc(sz);
	if(ptr)
		memZero(ptr,sz);
	return ptr;
}

void z_free(voidpf opaque, voidpf ptr)
{
	memFree(ptr);
}
