aboutsummaryrefslogtreecommitdiffstats
path: root/libavcodec
diff options
context:
space:
mode:
authorMichael Niedermayer <michaelni@gmx.at>2012-10-19 01:20:27 +0200
committerMichael Niedermayer <michaelni@gmx.at>2012-10-19 01:20:27 +0200
commit05b0337025f629d0a6c6321147f06d0da5e32a62 (patch)
tree11d7ca4e08838930db2779abc34f7d759fe12e92 /libavcodec
parentdf727d408c7e4aa7709ca62e3f693b98eac6213c (diff)
downloadffmpeg-05b0337025f629d0a6c6321147f06d0da5e32a62.tar.gz
motionpixels/mp_decode_frame_helper: assert that the first pixel doesnt reuse the last.
reusing the last would use uninitialized data, this should be impossible currently, but better to check by assert. Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
Diffstat (limited to 'libavcodec')
-rw-r--r--libavcodec/motionpixels.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/libavcodec/motionpixels.c b/libavcodec/motionpixels.c
index 471f63f5a5..73667130ac 100644
--- a/libavcodec/motionpixels.c
+++ b/libavcodec/motionpixels.c
@@ -220,6 +220,8 @@ static void mp_decode_frame_helper(MotionPixelsContext *mp, GetBitContext *gb)
YuvPixel p;
int y, y0;
+ av_assert1(mp->changes_map[0]);
+
for (y = 0; y < mp->avctx->height; ++y) {
if (mp->changes_map[y * mp->avctx->width] != 0) {
memset(mp->gradient_scale, 1, sizeof(mp->gradient_scale));