1
mirror of https://git.videolan.org/git/ffmpeg.git synced 2024-07-22 04:04:14 +02:00

avcodec/mpeg12dec: print the amount of overread

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
This commit is contained in:
Michael Niedermayer 2014-08-01 21:06:13 +02:00
parent f9bd6d61bc
commit 7f852962dc

View File

@ -1949,8 +1949,10 @@ static int mpeg_decode_slice(MpegEncContext *s, int mb_y,
}
}
eos: // end of slice
if (get_bits_left(&s->gb) < 0)
if (get_bits_left(&s->gb) < 0) {
av_log(s, AV_LOG_ERROR, "overread %d\n", -get_bits_left(&s->gb));
return AVERROR_INVALIDDATA;
}
*buf += (get_bits_count(&s->gb) - 1) / 8;
av_dlog(s, "y %d %d %d %d\n", s->resync_mb_x, s->resync_mb_y, s->mb_x, s->mb_y);
return 0;