Commit 730cdb5f by Craig Heffner

Fixed extraction bug where extracted files were rounded up to nearest block size.

parent 85c522b9
...@@ -695,8 +695,10 @@ class Extractor(Module): ...@@ -695,8 +695,10 @@ class Extractor(Module):
if not data: if not data:
break break
else: else:
fdout.write(str2bytes(data[adjust:dlen]))
total_size += (dlen-adjust) total_size += (dlen-adjust)
if total_size > size:
dlen -= (total_size - size)
fdout.write(str2bytes(data[adjust:dlen]))
adjust = 0 adjust = 0
# Cleanup # Cleanup
......
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