aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMax Justicz <maxj@mit.edu>2017-05-24 15:25:50 +0200
committerMichael Niedermayer <michael@niedermayer.cc>2017-06-02 01:14:38 +0200
commit861c05b286f2f4cf6c5a621977e3957bb6c30ad9 (patch)
tree31fb9e3d34c688c48390c891431a8e54f2d565e4
parentba7ea7c4b1aa0f3c4b65db4f218c54a97d0f942f (diff)
downloadffmpeg-861c05b286f2f4cf6c5a621977e3957bb6c30ad9.tar.gz
avcodec/sanm: Fix uninitialized reference frames
Fixes: poc.snm Signed-off-by: Michael Niedermayer <michael@niedermayer.cc> (cherry picked from commit ca616b0f72c65b0ef5f9e1e6125698b15f50a26e) Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
-rw-r--r--libavcodec/sanm.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/libavcodec/sanm.c b/libavcodec/sanm.c
index dab9e410c3..811fd2188e 100644
--- a/libavcodec/sanm.c
+++ b/libavcodec/sanm.c
@@ -462,11 +462,11 @@ static void destroy_buffers(SANMVideoContext *ctx)
static av_cold int init_buffers(SANMVideoContext *ctx)
{
- av_fast_padded_malloc(&ctx->frm0, &ctx->frm0_size, ctx->buf_size);
- av_fast_padded_malloc(&ctx->frm1, &ctx->frm1_size, ctx->buf_size);
- av_fast_padded_malloc(&ctx->frm2, &ctx->frm2_size, ctx->buf_size);
+ av_fast_padded_mallocz(&ctx->frm0, &ctx->frm0_size, ctx->buf_size);
+ av_fast_padded_mallocz(&ctx->frm1, &ctx->frm1_size, ctx->buf_size);
+ av_fast_padded_mallocz(&ctx->frm2, &ctx->frm2_size, ctx->buf_size);
if (!ctx->version)
- av_fast_padded_malloc(&ctx->stored_frame,
+ av_fast_padded_mallocz(&ctx->stored_frame,
&ctx->stored_frame_size, ctx->buf_size);
if (!ctx->frm0 || !ctx->frm1 || !ctx->frm2 ||