summaryrefslogtreecommitdiff
path: root/gzio.c
diff options
context:
space:
mode:
Diffstat (limited to 'gzio.c')
-rw-r--r--gzio.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/gzio.c b/gzio.c
index 14fc33c..1beb47f 100644
--- a/gzio.c
+++ b/gzio.c
@@ -506,7 +506,8 @@ int ZEXPORT gzungetc(c, file)
506 s->back = c; 506 s->back = c;
507 s->stream.total_out--; 507 s->stream.total_out--;
508 s->last = (s->z_err == Z_STREAM_END); 508 s->last = (s->z_err == Z_STREAM_END);
509 if (s->z_eof) s->z_eof = 0; 509 if (s->last) s->z_err = Z_OK;
510 s->z_eof = 0;
510 return c; 511 return c;
511} 512}
512 513
@@ -812,7 +813,7 @@ z_off_t ZEXPORT gzseek (file, offset, whence)
812 if (s->outbuf == Z_NULL) return -1L; 813 if (s->outbuf == Z_NULL) return -1L;
813 } 814 }
814 if (offset && s->back != EOF) { 815 if (offset && s->back != EOF) {
815 s->back == EOF; 816 s->back = EOF;
816 s->stream.total_out++; 817 s->stream.total_out++;
817 offset--; 818 offset--;
818 if (s->last) s->z_err = Z_STREAM_END; 819 if (s->last) s->z_err = Z_STREAM_END;