Commit 5ab08bc2 authored by Kazuhiko Shiozaki's avatar Kazuhiko Shiozaki Committed by Jérome Perrin

py2/py3: cast explicitly to bytes for possible Pdata.

parent e4c9ceae
...@@ -303,7 +303,7 @@ class OOoDocument(OOoDocumentExtensibleTraversableMixin, BaseConvertableFileMixi ...@@ -303,7 +303,7 @@ class OOoDocument(OOoDocumentExtensibleTraversableMixin, BaseConvertableFileMixi
# Extra processing required since # Extra processing required since
# we receive a zip file # we receive a zip file
cs = BytesIO() cs = BytesIO()
cs.write(data) cs.write(bytes(data))
z = zipfile.ZipFile(cs) # A disk file would be more RAM efficient z = zipfile.ZipFile(cs) # A disk file would be more RAM efficient
for f in z.infolist(): for f in z.infolist():
fn = f.filename fn = f.filename
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment