mirror of
https://github.com/FFmpeg/FFmpeg.git
synced 2025-01-13 21:28:01 +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:
parent
a83499b13b
commit
c084a975aa
@ -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;
|
||||
|
Loading…
Reference in New Issue
Block a user