Correct seek use

Harmless but misleading since both args are zero.
This commit is contained in:
2017-11-18 18:25:57 +11:00
parent c4f935159e
commit 7afb1fe606

View File

@@ -71,7 +71,7 @@ def open_blend(filename, access="rb"):
log.debug("decompressing finished")
fs.close()
log.debug("resetting decompressed file")
handle.seek(os.SEEK_SET, 0)
handle.seek(0, os.SEEK_SET)
bfile = BlendFile(handle)
bfile.is_compressed = True
bfile.filepath_orig = filename
@@ -183,7 +183,7 @@ class BlendFile:
if self.is_modified:
if self.is_compressed:
log.debug("close compressed blend file")
handle.seek(os.SEEK_SET, 0)
handle.seek(0, os.SEEK_SET)
log.debug("compressing started")
fs = gzip.open(self.filepath_orig, "wb")
data = handle.read(FILE_BUFFER_SIZE)