From b7fbee215674c3399212dffba1e71323056931d9 Mon Sep 17 00:00:00 2001 From: Mark Adler Date: Sat, 31 Dec 2016 08:49:17 -0800 Subject: Use a uniform approach for the largest value of an unsigned type. --- uncompr.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'uncompr.c') diff --git a/uncompr.c b/uncompr.c index 2fbfcc0..f03a1a8 100644 --- a/uncompr.c +++ b/uncompr.c @@ -32,7 +32,7 @@ int ZEXPORT uncompress2 (dest, destLen, source, sourceLen) { z_stream stream; int err; - const uInt max = (uInt)0 - 1; + const uInt max = (uInt)-1; uLong len, left; Byte buf[1]; /* for detection of incomplete stream when *destLen == 0 */ -- cgit v1.2.3-55-g6feb