[FFmpeg-cvslog] avcodec/g2meet: Fix potential overflow in tile dimensions check
Michael Niedermayer
git at videolan.org
Thu Nov 26 17:54:56 CET 2015
ffmpeg | branch: release/2.5 | Michael Niedermayer <michael at niedermayer.cc> | Fri Sep 4 12:10:02 2015 +0200| [9f825fa96e78cc60baa42e0122a8f8c2665f38f5] | committer: Michael Niedermayer
avcodec/g2meet: Fix potential overflow in tile dimensions check
Fixes CID1322351
Signed-off-by: Michael Niedermayer <michael at niedermayer.cc>
(cherry picked from commit 71ec8e1ed6cf4947e204e3e4b5929a44c054f5fb)
Signed-off-by: Michael Niedermayer <michael at niedermayer.cc>
> http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=9f825fa96e78cc60baa42e0122a8f8c2665f38f5
---
libavcodec/g2meet.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/libavcodec/g2meet.c b/libavcodec/g2meet.c
index 0cd502b..e99eba4 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",
More information about the ffmpeg-cvslog
mailing list