From 89963a948085d2b460ed923d4af9ae61ef460775 Mon Sep 17 00:00:00 2001 From: Marek Nogacki Date: Tue, 13 Oct 2015 14:49:00 +0200 Subject: [PATCH] Fix some JPEG images identified as MPO --- PIL/JpegImagePlugin.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/PIL/JpegImagePlugin.py b/PIL/JpegImagePlugin.py index 577951961..046e13947 100644 --- a/PIL/JpegImagePlugin.py +++ b/PIL/JpegImagePlugin.py @@ -713,7 +713,7 @@ def jpeg_factory(fp=None, filename=None): # It's actually an MPO from .MpoImagePlugin import MpoImageFile im = MpoImageFile(fp, filename) - except (TypeError, IndexError): + except (TypeError, IndexError, ValueError): # It is really a JPEG pass except SyntaxError: