This commit is contained in:
Roland Netzsch 2017-10-05 09:54:18 +02:00 committed by GitHub
parent 1d18a5cfef
commit f29fe99d22

View File

@ -728,7 +728,9 @@ def _save(im, fp, filename, chunk=putchunk, check=0):
name = b"ICC Profile"
data = name + b"\0\0" + zlib.compress(icc)
chunk(fp, b"iCCP", data)
else:
# You must either have sRGB or iCCP.
# Disallow sRGB chunks when a iCCP-chunk has been emitted.
chunks.remove(b"sRGB")
info = im.encoderinfo.get("pnginfo")