mirror of
https://github.com/python-pillow/Pillow.git
synced 2025-09-26 05:56:55 +03:00
Use greater than or equal for version check
Co-authored-by: Hugo van Kemenade <1324225+hugovk@users.noreply.github.com>
This commit is contained in:
parent
779715277e
commit
f4d0474d98
|
@ -521,10 +521,10 @@ def extract_dep(url: str, filename: str, prefs: dict[str, str]) -> None:
|
||||||
if sources_dir_abs != member_prefix:
|
if sources_dir_abs != member_prefix:
|
||||||
msg = "Attempted Path Traversal in Tar File"
|
msg = "Attempted Path Traversal in Tar File"
|
||||||
raise RuntimeError(msg)
|
raise RuntimeError(msg)
|
||||||
if sys.version_info <= (3, 11):
|
if sys.version_info >= (3, 12):
|
||||||
tgz.extractall(sources_dir)
|
|
||||||
else:
|
|
||||||
tgz.extractall(sources_dir, filter="data")
|
tgz.extractall(sources_dir, filter="data")
|
||||||
|
else:
|
||||||
|
tgz.extractall(sources_dir)
|
||||||
else:
|
else:
|
||||||
msg = "Unknown archive type: " + filename
|
msg = "Unknown archive type: " + filename
|
||||||
raise RuntimeError(msg)
|
raise RuntimeError(msg)
|
||||||
|
|
Loading…
Reference in New Issue
Block a user