Skip to content

Commit

Permalink
Merge pull request #5659 from wiredfool/fli_framesize
Browse files Browse the repository at this point in the history
  • Loading branch information
hugovk committed Sep 5, 2021
2 parents 98319ef + 8f300af commit 65b5f91
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/libImaging/FliDecode.c
Expand Up @@ -46,7 +46,8 @@ ImagingFliDecode(Imaging im, ImagingCodecState state, UINT8 *buf, Py_ssize_t byt
ptr = buf;

framesize = I32(ptr);
if (framesize < I32(ptr)) {
// there can be one pad byte in the framesize
if (bytes + (bytes % 2) < framesize) {
return 0;
}

Expand Down

0 comments on commit 65b5f91

Please sign in to comment.