mirror of
https://git.ffmpeg.org/ffmpeg.git
synced 2025-12-08 06:09:50 +00:00
avcodec_alloc_frame: dont zero the whole struct twice
cleaning it up is already done in avcodec_get_frame_defaults() Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
This commit is contained in:
parent
d9d56712e9
commit
8deddc6961
1 changed files with 2 additions and 1 deletions
|
|
@ -720,11 +720,12 @@ void avcodec_get_frame_defaults(AVFrame *frame)
|
|||
|
||||
AVFrame *avcodec_alloc_frame(void)
|
||||
{
|
||||
AVFrame *frame = av_mallocz(sizeof(AVFrame));
|
||||
AVFrame *frame = av_malloc(sizeof(AVFrame));
|
||||
|
||||
if (frame == NULL)
|
||||
return NULL;
|
||||
|
||||
frame->extended_data = NULL;
|
||||
avcodec_get_frame_defaults(frame);
|
||||
|
||||
return frame;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue