From 33e1ffe5706306bea8cfc9802e61f59364736583 Mon Sep 17 00:00:00 2001 From: Tom Gross Date: Thu, 26 Apr 2012 17:00:22 +0200 Subject: [PATCH] fixed reading of EPS pictures found in: http://www.mail-archive.com/image-sig@python.org/msg03054.html --- PIL/EpsImagePlugin.py | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/PIL/EpsImagePlugin.py b/PIL/EpsImagePlugin.py index 1927b3227..837447bca 100644 --- a/PIL/EpsImagePlugin.py +++ b/PIL/EpsImagePlugin.py @@ -202,6 +202,10 @@ class EpsImageFile(ImageFile.ImageFile): self.info[k[:8]] = k[9:] else: self.info[k] = "" + elif s[0] == '%': + # handle non-DSC Postscript comments that some + # tools mistakenly put in the Comments section + pass else: raise IOError, "bad EPS header"