Revert a14467f fixes #1462 again

This commit is contained in:
Lorenz Schori 2016-04-16 14:57:20 +01:00
parent ac6e1ef949
commit 4c526963a4
3 changed files with 4 additions and 2 deletions

View File

@ -554,6 +554,8 @@ class ImageFileDirectory_v2(collections.MutableMapping):
if info.length == 1:
if legacy_api and self.tagtype[tag] in [5, 10]:
values = values,
elif not legacy_api and self.tagtype[tag] == 1:
values = values,
dest[tag], = values
else:
dest[tag] = values

View File

@ -152,7 +152,7 @@ TAGS_V2 = {
# FIXME add more tags here
34665: ("ExifIFD", SHORT, 1),
34675: ('ICCProfile', 7, 0),
34675: ('ICCProfile', 7, 1),
34853: ('GPSInfoIFD', 1, 1),
# MPInfo

View File

@ -175,7 +175,7 @@ class TestFileTiffMetadata(PillowTestCase):
im.save(out)
reloaded = Image.open(out)
self.assert_(type(im.info['icc_profile']) is not type(tuple))
self.assertNotEqual(type(im.info['icc_profile']), tuple)
self.assertEqual(im.info['icc_profile'], reloaded.info['icc_profile'])
def test_iccprofile_binary(self):