diff options
author | Michael Niedermayer <michaelni@gmx.at> | 2011-09-17 19:40:25 +0200 |
---|---|---|
committer | Michael Niedermayer <michaelni@gmx.at> | 2011-09-21 20:56:53 +0200 |
commit | ed9e561490d70e317659f9e406c7920242e509eb (patch) | |
tree | e0a7df43fbfdeb2b394c834c38d65fd99ff58521 | |
parent | 24e0a9e451e1aae427307a919d78f6790f4e413c (diff) | |
download | ffmpeg-ed9e561490d70e317659f9e406c7920242e509eb.tar.gz |
rv34: check for size mismatch
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
(cherry picked from commit 35f38b3ab9d755aede5bce8abbe1cb9c07027f8a)
-rw-r--r-- | libavcodec/rv34.c | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/libavcodec/rv34.c b/libavcodec/rv34.c index ba88916f5d..0e5f868390 100644 --- a/libavcodec/rv34.c +++ b/libavcodec/rv34.c @@ -1312,6 +1312,10 @@ static int rv34_decode_slice(RV34DecContext *r, int end, const uint8_t* buf, int av_log(s->avctx, AV_LOG_ERROR, "Slice type mismatch\n"); return AVERROR_INVALIDDATA; } + if (s->width != r->si.width || s->height != r->si.height) { + av_log(s->avctx, AV_LOG_ERROR, "Size mismatch\n"); + return AVERROR_INVALIDDATA; + } } r->si.end = end; |