[FFmpeg-cvslog] cmdutils: reset *picref_ptr to NULL in get_filtered_frame()

Stefano Sabatini git at videolan.org
Fri May 20 10:10:04 CEST 2011


ffmpeg | branch: master | Stefano Sabatini <stefano.sabatini-lala at poste.it> | Fri May 20 00:58:00 2011 +0200| [0d65e0f8cb0f924be95650f50f3d05d0b223aceb] | committer: Stefano Sabatini

cmdutils: reset *picref_ptr to NULL in get_filtered_frame()

Avoid the presence of an invalid pointer, fix a crash in case of
get_filtered_frame() failure.

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

 cmdutils.c |    1 +
 1 files changed, 1 insertions(+), 0 deletions(-)

diff --git a/cmdutils.c b/cmdutils.c
index a5363b8..71d6d33 100644
--- a/cmdutils.c
+++ b/cmdutils.c
@@ -908,6 +908,7 @@ int get_filtered_video_frame(AVFilterContext *ctx, AVFrame *frame,
 {
     int ret;
     AVFilterBufferRef *picref;
+    *picref_ptr = NULL;
 
     if ((ret = avfilter_request_frame(ctx->inputs[0])) < 0)
         return ret;



More information about the ffmpeg-cvslog mailing list