1
0
mirror of https://github.com/FFmpeg/FFmpeg.git synced 2025-08-15 14:13:16 +02:00

lavc: use av_mallocz to allocate AVFrames.

Otherwise the frame is uninitialized, so avcodec_get_frame_defaults()
cannot determine whether to free extended_data.
This commit is contained in:
Anton Khirnov
2012-09-24 07:17:13 +02:00
parent a83499b13b
commit c084a975aa

View File

@@ -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;