We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 5ba72a9 commit 237aea4Copy full SHA for 237aea4
src/PIL/GimpPaletteFile.py
@@ -45,7 +45,7 @@ def __init__(self, fp: IO[bytes]) -> None:
45
msg = "bad palette file"
46
raise SyntaxError(msg)
47
48
- v = tuple(map(int, s.split()[:3]))
+ v = tuple(map(int, s.split(maxsplit=3)[:3]))
49
if len(v) != 3:
50
msg = "bad palette entry"
51
raise ValueError(msg)
0 commit comments