Commit be24c681 authored by jvoisin's avatar jvoisin

Improve the reliability of PNG parsing

parent efa525c1
Pipeline #31814 passed with stages
in 2 minutes and 31 seconds
......@@ -63,7 +63,8 @@ class PNGParser(exiftool.ExiftoolParser):
try: # better fail here than later
cairo.ImageSurface.create_from_png(self.filename)
except MemoryError: # pragma: no cover
except Exception: # pragma: no cover
# Cairo is returning some weird exceptions :/
raise ValueError
def remove_all(self) -> bool:
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment