Merge pull request #137 from caujka/master
Handling for EOF reading error in gzipped content
This commit is contained in:
commit
c4d03d8b85
|
@ -54,7 +54,7 @@ def decode_gzip(content):
|
|||
gfile = gzip.GzipFile(fileobj=cStringIO.StringIO(content))
|
||||
try:
|
||||
return gfile.read()
|
||||
except IOError:
|
||||
except (IOError, EOFError):
|
||||
return None
|
||||
|
||||
def encode_gzip(content):
|
||||
|
|
Loading…
Reference in New Issue