提交 56de2897 编写于 作者: D Dale Curtis 提交者: Vittorio Giovara

h264: Fix memory leak on ff_h264_decode_init() failure

CC: libav-devel@libav.org
上级 2e093596
......@@ -662,8 +662,10 @@ av_cold int ff_h264_decode_init(AVCodecContext *avctx)
if (avctx->extradata_size > 0 && avctx->extradata) {
ret = ff_h264_decode_extradata(h);
if (ret < 0)
if (ret < 0) {
ff_h264_free_context(h);
return ret;
}
}
if (h->sps.bitstream_restriction_flag &&
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册