From afff7a4817f798a7546771e7ead2abdedae1bbf0 Mon Sep 17 00:00:00 2001 From: John Cavanaugh Date: Sun, 15 Jul 2012 00:42:17 -0700 Subject: [PATCH] Fix for situations when makernotes entries do not exist --- EXIF.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/EXIF.py b/EXIF.py index 0779ca18..7579779a 100755 --- a/EXIF.py +++ b/EXIF.py @@ -1585,7 +1585,8 @@ def decode_maker_note(self): dict=MAKERNOTE_CANON_TAGS) for i in (('MakerNote Tag 0x0001', MAKERNOTE_CANON_TAG_0x001), ('MakerNote Tag 0x0004', MAKERNOTE_CANON_TAG_0x004)): - self.canon_decode_tag(self.tags[i[0]].values, i[1]) + if i[0] in self.tags: + self.canon_decode_tag(self.tags[i[0]].values, i[1]) return