1
0
mirror of https://github.com/FFmpeg/FFmpeg.git synced 2024-11-26 19:01:44 +02:00

mpeg4videodec: check resolution marker bits

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
This commit is contained in:
Michael Niedermayer 2013-08-11 17:34:29 +02:00
parent 5717689c75
commit 06137a496b

View File

@ -1626,11 +1626,11 @@ static int decode_vol_header(MpegEncContext *s, GetBitContext *gb){
if (s->shape != BIN_ONLY_SHAPE) {
if (s->shape == RECT_SHAPE) {
skip_bits1(gb); /* marker */
check_marker(gb, "before width");
width = get_bits(gb, 13);
skip_bits1(gb); /* marker */
check_marker(gb, "before height");
height = get_bits(gb, 13);
skip_bits1(gb); /* marker */
check_marker(gb, "after height");
if(width && height && !(s->width && s->codec_tag == AV_RL32("MP4S"))){ /* they should be non zero but who knows ... */
if (s->width && s->height &&
(s->width != width || s->height != height))