1
0
mirror of https://github.com/FFmpeg/FFmpeg.git synced 2024-11-26 19:01:44 +02: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:
Michael Niedermayer 2012-09-25 17:36:17 +02:00
parent d9d56712e9
commit 8deddc6961

View File

@ -720,11 +720,12 @@ void avcodec_get_frame_defaults(AVFrame *frame)
AVFrame *avcodec_alloc_frame(void) AVFrame *avcodec_alloc_frame(void)
{ {
AVFrame *frame = av_mallocz(sizeof(AVFrame)); AVFrame *frame = av_malloc(sizeof(AVFrame));
if (frame == NULL) if (frame == NULL)
return NULL; return NULL;
frame->extended_data = NULL;
avcodec_get_frame_defaults(frame); avcodec_get_frame_defaults(frame);
return frame; return frame;