summaryrefslogtreecommitdiff
path: root/libavcodec/exr.c
diff options
context:
space:
mode:
Diffstat (limited to 'libavcodec/exr.c')
-rw-r--r--libavcodec/exr.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/libavcodec/exr.c b/libavcodec/exr.c
index fed4c127b8..9377a89169 100644
--- a/libavcodec/exr.c
+++ b/libavcodec/exr.c
@@ -1795,6 +1795,7 @@ static int decode_header(EXRContext *s, AVFrame *frame)
ymax = bytestream2_get_le32(gb);
if (xmin > xmax || ymin > ymax ||
+ ymax == INT_MAX || xmax == INT_MAX ||
(unsigned)xmax - xmin >= INT_MAX ||
(unsigned)ymax - ymin >= INT_MAX) {
ret = AVERROR_INVALIDDATA;