diff --git a/PIL/JpegImagePlugin.py b/PIL/JpegImagePlugin.py index da8c6922d..b1c25db1d 100644 --- a/PIL/JpegImagePlugin.py +++ b/PIL/JpegImagePlugin.py @@ -433,7 +433,7 @@ def _getexif(self): # get gpsinfo extension try: file.seek(exif[0x8825]) - except KeyError: + except (KeyError, TypeError): pass else: info = TiffImagePlugin.ImageFileDirectory(head)