Commit Diff


commit - afbfc7fb1894f033414e690ac1e2260b5b2c79d8
commit + 8baa7d2656b89e5d4536a655d0e6cfacdf32549a
blob - 1dfd4a723e97bc08d71f8821edc65f5a1aa93b88
blob + a69a6ffcc255caa3dfdcb05db84a92a917826b23
--- lib/inflate.c
+++ lib/inflate.c
@@ -107,7 +107,7 @@ got_inflate_read(struct got_inflate_buf *zb, FILE *f, 
 		ret = inflate(z, Z_SYNC_FLUSH);
 	} while (ret == Z_OK && z->avail_out > 0);
 
-	if (ret == Z_OK) {
+	if (ret == Z_OK || ret == Z_BUF_ERROR) {
 		zb->flags |= GOT_INFLATE_F_HAVE_MORE;
 	} else {
 		if (ret != Z_STREAM_END)