Skip to content

Commit 307ee30

Browse files
committed
Update ZipInfo._end_offset
1 parent e3269cc commit 307ee30

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

Lib/zipfile/__init__.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1998,6 +1998,8 @@ def _remove_members(self, members, *, remove_physical=True, chunk_size=2**20):
19981998
if remove_physical:
19991999
old_header_offset = info.header_offset
20002000
info.header_offset -= entry_offset
2001+
if info._end_offset is not None:
2002+
info._end_offset -= entry_offset
20012003
read_size = 0
20022004
while read_size < entry_size:
20032005
fp.seek(old_header_offset + read_size)

0 commit comments

Comments
 (0)