Skip to content
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Next Next commit
zipfile: Add missing check for zstd compression when writing end record
  • Loading branch information
pR0Ps committed May 9, 2025
commit 114044fe91df7c75c3939821e57a3ec006fb14bc
2 changes: 2 additions & 0 deletions Lib/zipfile/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -2093,6 +2093,8 @@ def _write_end_record(self):
min_version = max(BZIP2_VERSION, min_version)
elif zinfo.compress_type == ZIP_LZMA:
min_version = max(LZMA_VERSION, min_version)
elif zinfo.compress_type == ZIP_ZSTANDARD:
min_version = max(ZSTANDARD_VERSION, min_version)

extract_version = max(min_version, zinfo.extract_version)
create_version = max(min_version, zinfo.create_version)
Expand Down