Commit 39ff027f authored by Michael Niedermayer's avatar Michael Niedermayer

avcodec/mpeg12enc: Add FF_CODEC_CAP_INIT_CLEANUP

Fixes: Multiple memleaks
Fixes: ffmpeg-memory-leak
Found-by: 's avatarFrancis Provencher <francis@protekresearchlab.com>
Signed-off-by: 's avatarMichael Niedermayer <michael@niedermayer.cc>
parent e1255789
......@@ -1193,6 +1193,7 @@ AVCodec ff_mpeg1video_encoder = {
.pix_fmts = (const enum AVPixelFormat[]) { AV_PIX_FMT_YUV420P,
AV_PIX_FMT_NONE },
.capabilities = AV_CODEC_CAP_DELAY | AV_CODEC_CAP_SLICE_THREADS,
.caps_internal = FF_CODEC_CAP_INIT_CLEANUP,
.priv_class = &mpeg1_class,
};
......@@ -1210,5 +1211,6 @@ AVCodec ff_mpeg2video_encoder = {
AV_PIX_FMT_YUV422P,
AV_PIX_FMT_NONE },
.capabilities = AV_CODEC_CAP_DELAY | AV_CODEC_CAP_SLICE_THREADS,
.caps_internal = FF_CODEC_CAP_INIT_CLEANUP,
.priv_class = &mpeg2_class,
};
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment