aboutsummaryrefslogtreecommitdiffstats
path: root/libavcodec
diff options
context:
space:
mode:
authorPaul B. Mahol <onemda@gmail.com>2011-12-17 17:58:06 +0000
committerJanne Grunau <janne-libav@jannau.net>2011-12-18 23:52:53 +0100
commit2e7905eee8d0f8813e703cacdd7b3ffdc4960656 (patch)
treed5544a1fc6e623009552f00cd1041bf1ff82c0c8 /libavcodec
parent652d81b2c2201922f0fef2bbd171299ce3798d12 (diff)
downloadffmpeg-2e7905eee8d0f8813e703cacdd7b3ffdc4960656.tar.gz
cljr: fix buf_size sanity check
Signed-off-by: Janne Grunau <janne-libav@jannau.net>
Diffstat (limited to 'libavcodec')
-rw-r--r--libavcodec/cljr.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/libavcodec/cljr.c b/libavcodec/cljr.c
index f40d4d17ce..cf307bb06a 100644
--- a/libavcodec/cljr.c
+++ b/libavcodec/cljr.c
@@ -62,7 +62,7 @@ static int decode_frame(AVCodecContext *avctx,
return AVERROR_INVALIDDATA;
}
- if (buf_size / avctx->height < avctx->width) {
+ if (buf_size < avctx->height * avctx->width) {
av_log(avctx, AV_LOG_ERROR,
"Resolution larger than buffer size. Invalid header?\n");
return AVERROR_INVALIDDATA;