IntelExtractor: Fix unlocked removal of irrelevant files

This commit is contained in:
RichardG867
2022-05-23 17:01:34 -03:00
parent 9ff0ddc590
commit c109c49391

View File

@@ -1487,6 +1487,9 @@ class IntelExtractor(Extractor):
# Stop if this file has an irrelevant extension.
file_name_lower = file_name.lower()
if file_name_lower[-3:] not in self._part_extensions:
# Acquire the multi-file lock.
self.multifile_lock_acquire(file_path)
# Remove file.
try:
os.remove(file_path)