aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMichael Niedermayer <michael@niedermayer.cc>2015-09-04 12:10:02 +0200
committerMichael Niedermayer <michael@niedermayer.cc>2015-12-06 12:40:48 +0100
commit47b6ea314df6df4021690a98616d3fa73e07d0df (patch)
tree8fc134a6acd5aaf2b40829edc4f0499d4642607b
parent45c30d84b6c57b529687096bd7043c6999bd2d14 (diff)
downloadffmpeg-47b6ea314df6df4021690a98616d3fa73e07d0df.tar.gz
avcodec/g2meet: Fix potential overflow in tile dimensions check
Fixes CID1322351 Signed-off-by: Michael Niedermayer <michael@niedermayer.cc> (cherry picked from commit 71ec8e1ed6cf4947e204e3e4b5929a44c054f5fb) Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
-rw-r--r--libavcodec/g2meet.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/libavcodec/g2meet.c b/libavcodec/g2meet.c
index d0cb88cb56..302dc9dfdc 100644
--- a/libavcodec/g2meet.c
+++ b/libavcodec/g2meet.c
@@ -738,7 +738,7 @@ static int g2m_decode_frame(AVCodecContext *avctx, void *data,
c->tile_height = bytestream2_get_be32(&bc);
if (c->tile_width <= 0 || c->tile_height <= 0 ||
((c->tile_width | c->tile_height) & 0xF) ||
- c->tile_width * 4LL * c->tile_height >= INT_MAX
+ c->tile_width * (uint64_t)c->tile_height >= INT_MAX / 4
) {
av_log(avctx, AV_LOG_ERROR,
"Invalid tile dimensions %dx%d\n",