diff options
author | Laurent Aimar <fenrir@videolan.org> | 2011-09-30 00:05:48 +0200 |
---|---|---|
committer | Michael Niedermayer <michaelni@gmx.at> | 2011-10-01 20:54:26 +0200 |
commit | 376b0994746cbb14438c2a58ea1bdb2c9b934610 (patch) | |
tree | 7f580194248fd9b3ed9fd430a06537a6ab722824 | |
parent | 6e774cf67e6f30feb9b3dec11713d6b6dc0b521c (diff) | |
download | ffmpeg-376b0994746cbb14438c2a58ea1bdb2c9b934610.tar.gz |
Clear FF_INPUT_BUFFER_PADDING_SIZE bytes at the end of the temporary buffer used in motion pixels decoder.
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
(cherry picked from commit e60619f9b4bdaf9af46887cdb2c86454567b4a61)
-rw-r--r-- | libavcodec/motionpixels.c | 1 | ||||
-rw-r--r-- | tests/ref/fate/motionpixels | 2 |
2 files changed, 2 insertions, 1 deletions
diff --git a/libavcodec/motionpixels.c b/libavcodec/motionpixels.c index 4bd83cb2ae..a3afc02582 100644 --- a/libavcodec/motionpixels.c +++ b/libavcodec/motionpixels.c @@ -253,6 +253,7 @@ static int mp_decode_frame(AVCodecContext *avctx, mp->dsp.bswap_buf((uint32_t *)mp->bswapbuf, (const uint32_t *)buf, buf_size / 4); if (buf_size & 3) memcpy(mp->bswapbuf + (buf_size & ~3), buf + (buf_size & ~3), buf_size & 3); + memset(mp->bswapbuf + buf_size, 0, FF_INPUT_BUFFER_PADDING_SIZE); init_get_bits(&gb, mp->bswapbuf, buf_size * 8); memset(mp->changes_map, 0, avctx->width * avctx->height); diff --git a/tests/ref/fate/motionpixels b/tests/ref/fate/motionpixels index e588ed3e18..30651e92c6 100644 --- a/tests/ref/fate/motionpixels +++ b/tests/ref/fate/motionpixels @@ -109,4 +109,4 @@ 0, 648003, 230400, 0xb343f372 0, 654003, 230400, 0xf7f1e588 0, 660003, 230400, 0x9682bdb2 -0, 666003, 230400, 0x538a3db8 +0, 666003, 230400, 0x16f9aad8 |