zlib 1.0.2

This commit is contained in:
Mark Adler
2011-09-09 23:15:17 -07:00
parent 423eb40306
commit e26a448e96
22 changed files with 380 additions and 120 deletions

View File

@@ -3,7 +3,7 @@
* For conditions of distribution and use, see copyright notice in zlib.h
*/
/* $Id: compress.c,v 1.9 1996/01/30 21:59:09 me Exp $ */
/* $Id: compress.c,v 1.10 1996/05/23 16:51:12 me Exp $ */
#include "zlib.h"
@@ -30,9 +30,10 @@ int compress (dest, destLen, source, sourceLen)
stream.next_in = (Bytef*)source;
stream.avail_in = (uInt)sourceLen;
#ifdef MAXSEG_64K
/* Check for source > 64K on 16-bit machine: */
if ((uLong)stream.avail_in != sourceLen) return Z_BUF_ERROR;
#endif
stream.next_out = dest;
stream.avail_out = (uInt)*destLen;
if ((uLong)stream.avail_out != *destLen) return Z_BUF_ERROR;