summaryrefslogtreecommitdiff
path: root/gzread.c
diff options
context:
space:
mode:
authorMika Lindqvist <postmaster@raasu.org>2017-02-13 21:50:12 +0200
committerMika Lindqvist <postmaster@raasu.org>2017-02-13 23:36:20 +0200
commit174ee8972db99eb771902169ce6ee78b28c28810 (patch)
tree1e3095e1dd3000e542670890e57d54d2fa6085e7 /gzread.c
parentb65b5c8905a77a3b2fa9c1e0385bce07713b5504 (diff)
Fix build with nmake.
Diffstat (limited to 'gzread.c')
-rw-r--r--gzread.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/gzread.c b/gzread.c
index 0928310..50b9244 100644
--- a/gzread.c
+++ b/gzread.c
@@ -286,7 +286,7 @@ static size_t gz_read(gz_statep state, void *buf, size_t len) {
/* set n to the maximum amount of len that fits in an unsigned int */
n = -1;
if (n > len)
- n = len;
+ n = (unsigned)len;
/* first just try copying data from the output buffer */
if (state->x.have) {
@@ -363,7 +363,7 @@ int ZEXPORT gzread(gzFile file, void *buf, unsigned len) {
}
/* read len or fewer bytes to buf */
- len = gz_read(state, buf, len);
+ len = (unsigned)gz_read(state, buf, len);
/* check for an error */
if (len == 0 && state->err != Z_OK && state->err != Z_BUF_ERROR)
@@ -423,7 +423,7 @@ int ZEXPORT gzgetc(gzFile file) {
}
/* nothing there -- try gz_read() */
- ret = gz_read(state, buf, 1);
+ ret = (int)gz_read(state, buf, 1);
return ret < 1 ? -1 : buf[0];
}