From 505b0ce38f7cecfd461608c89dabc7721ee4585d Mon Sep 17 00:00:00 2001 From: DarkPhoenix Date: Thu, 23 Jul 2015 20:34:02 +0300 Subject: [PATCH] Clear info dicts in-place instead of replacing them with new ones Sometimes it can cause fuckups, so who knows how PIL works with them... --- scripts/icons_update.py | 2 +- scripts/renders_update.py | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/scripts/icons_update.py b/scripts/icons_update.py index 0cf73f2b7..1ab128c4d 100644 --- a/scripts/icons_update.py +++ b/scripts/icons_update.py @@ -211,7 +211,7 @@ def get_icon_file(request): img = Image.open(fullpath) # Strip all additional image info (mostly for ICC color # profiles, see issue #337) - img.info = {} + img.info.clear() return img diff --git a/scripts/renders_update.py b/scripts/renders_update.py index 5ddf39b90..ffa488e9f 100644 --- a/scripts/renders_update.py +++ b/scripts/renders_update.py @@ -82,7 +82,7 @@ def get_render(type_id): img.thumbnail(RENDER_SIZE, Image.ANTIALIAS) # Strip all additional image info (mostly for ICC color # profiles, see issue #337) - img.info = {} + img.info.clear() return img