fix: [ocr] catch OSError on MP4 files

This commit is contained in:
terrtia 2024-04-30 10:17:04 +02:00
parent 31b519cc17
commit 50ff7529d2
No known key found for this signature in database
GPG key ID: 1E1B1F50D84613D0

View file

@ -103,7 +103,7 @@ class OcrExtractor(AbstractModule):
print(image.id, languages)
try:
texts = Ocrs.extract_text(path, languages)
except ValueError as e:
except (OSError, ValueError) as e:
self.logger.warning(e)
self.obj.add_tag('infoleak:confirmed="false-positive"')
texts = None