From adfda1a5a41f888226957906f4de51839c7ef407 Mon Sep 17 00:00:00 2001 From: hugovk Date: Wed, 30 Nov 2016 16:50:44 +0200 Subject: [PATCH] Python 3 compatibility --- PIL/IcoImagePlugin.py | 1 + 1 file changed, 1 insertion(+) diff --git a/PIL/IcoImagePlugin.py b/PIL/IcoImagePlugin.py index 195bbe42e..3436ae84f 100644 --- a/PIL/IcoImagePlugin.py +++ b/PIL/IcoImagePlugin.py @@ -49,6 +49,7 @@ def _save(im, fp, filename): sizes = filter(lambda x: False if (x[0] > width or x[1] > height or x[0] > 256 or x[1] > 256) else True, sizes) + sizes = list(sizes) fp.write(struct.pack("