[FFmpeg-cvslog] vda: better frame allocation

Sebastien Zwickert git at videolan.org
Tue Aug 14 15:39:44 CEST 2012


ffmpeg | branch: master | Sebastien Zwickert <dilaroga at gmail.com> | Tue Aug 14 11:47:39 2012 +0200| [694be29f13622c6b38c747c3bb14c93c95435c4d] | committer: Diego Biurrun

vda: better frame allocation

Signed-off-by: Diego Biurrun <diego at biurrun.de>

> http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=694be29f13622c6b38c747c3bb14c93c95435c4d
---

 libavcodec/vda_h264.c |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/libavcodec/vda_h264.c b/libavcodec/vda_h264.c
index 2d2d228..5c8f567 100644
--- a/libavcodec/vda_h264.c
+++ b/libavcodec/vda_h264.c
@@ -144,7 +144,7 @@ static void vda_decoder_callback(void *vda_hw_ctx,
         vda_frame *new_frame;
         vda_frame *queue_walker;
 
-        if (!(new_frame = av_mallocz(sizeof(vda_frame))))
+        if (!(new_frame = av_mallocz(sizeof(*new_frame))))
             return;
         new_frame->next_frame = NULL;
         new_frame->cv_buffer  = CVPixelBufferRetain(image_buffer);



More information about the ffmpeg-cvslog mailing list