mirror of
https://github.com/python-pillow/Pillow.git
synced 2025-04-28 21:13:41 +03:00
Ensure disposal key exists before checking
This commit is contained in:
parent
ae194096d0
commit
1f6d1be7fc
|
@ -443,7 +443,7 @@ def _write_multiple_frames(im, fp, palette):
|
||||||
if im_frames:
|
if im_frames:
|
||||||
# delta frame
|
# delta frame
|
||||||
previous = im_frames[-1]
|
previous = im_frames[-1]
|
||||||
if encoderinfo["disposal"] == 2:
|
if "disposal" in encoderinfo and encoderinfo["disposal"] == 2:
|
||||||
# If diposing whole frame, treat full new frame as delta
|
# If diposing whole frame, treat full new frame as delta
|
||||||
delta = im_frame
|
delta = im_frame
|
||||||
elif _get_palette_bytes(im_frame) == \
|
elif _get_palette_bytes(im_frame) == \
|
||||||
|
|
Loading…
Reference in New Issue
Block a user