From ca50ebd4dfd08dfd7e8c8bb087278e158cd67720 Mon Sep 17 00:00:00 2001 From: Mark Adler Date: Sat, 3 Dec 2016 10:27:14 -0800 Subject: Create z_size_t and z_ssize_t types. Normally these are set to size_t and ssize_t. But if they do not exist, then they are set to the smallest integer type that can contain a pointer. size_t is unsigned and ssize_t is signed. --- gzlib.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'gzlib.c') diff --git a/gzlib.c b/gzlib.c index a52c55b..3b2b71b 100644 --- a/gzlib.c +++ b/gzlib.c @@ -94,7 +94,7 @@ local gzFile gz_open(path, fd, mode) const char *mode; { gz_statep state; - size_t len; + z_size_t len; int oflag; #ifdef O_CLOEXEC int cloexec = 0; @@ -191,7 +191,7 @@ local gzFile gz_open(path, fd, mode) #ifdef WIDECHAR if (fd == -2) { len = wcstombs(NULL, path, 0); - if (len == (size_t)-1) + if (len == (z_size_t)-1) len = 0; } else -- cgit v1.2.3-55-g6feb