[FFmpeg-devel] [PATCH] lavfi/scale: return error code in case of failed reconfiguration in start_frame()

Stefano Sabatini stefasab at gmail.com
Mon Oct 15 09:47:35 CEST 2012


Avoid an assert, since now the function supports error code return.
---
 libavfilter/vf_scale.c |    3 +--
 1 files changed, 1 insertions(+), 2 deletions(-)

diff --git a/libavfilter/vf_scale.c b/libavfilter/vf_scale.c
index 8921f69..c9def01 100644
--- a/libavfilter/vf_scale.c
+++ b/libavfilter/vf_scale.c
@@ -315,10 +315,9 @@ static int start_frame(AVFilterLink *link, AVFilterBufferRef *picref)
         link->dst->inputs[0]->h      = picref->video->h;
 
         if ((ret = config_props(outlink)) < 0)
-            av_assert0(0); //what to do here ?
+            return ret;
     }
 
-
     if (!scale->sws) {
         outpicref = avfilter_ref_buffer(picref, ~0);
         if (!outpicref)
-- 
1.7.5.4



More information about the ffmpeg-devel mailing list