From ee99e68a67d2c450d17ca68557313ec36520e874 Mon Sep 17 00:00:00 2001 From: Joseph Schorr Date: Wed, 15 Oct 2014 17:24:17 -0400 Subject: [PATCH] Fix gzip wrap to keep reading from the buffer once the inner loop has completed --- util/gzipwrap.py | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/util/gzipwrap.py b/util/gzipwrap.py index c44615b73..e34fa5745 100644 --- a/util/gzipwrap.py +++ b/util/gzipwrap.py @@ -11,12 +11,9 @@ class GzipWrap(object): self.is_done = False def read(self, size=-1): - if self.is_done: - return '' - # If the buffer already has enough bytes, then simply pop them off of # the beginning and return them. - if len(self.buffer) >= size: + if len(self.buffer) >= size or self.is_done: ret = self.buffer[0:size] self.buffer = self.buffer[size:] return ret