提交 c084a975 编写于 作者: A Anton Khirnov

lavc: use av_mallocz to allocate AVFrames.

Otherwise the frame is uninitialized, so avcodec_get_frame_defaults()
cannot determine whether to free extended_data.
上级 a83499b1
......@@ -645,7 +645,7 @@ void avcodec_get_frame_defaults(AVFrame *frame)
AVFrame *avcodec_alloc_frame(void)
{
AVFrame *frame = av_malloc(sizeof(AVFrame));
AVFrame *frame = av_mallocz(sizeof(AVFrame));
if (frame == NULL)
return NULL;
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册