scale_npp: fix passthrough mode
authorYogender Gupta <ygupta@nvidia.com>
Mon, 24 Oct 2016 12:56:41 +0000 (18:26 +0530)
committerAnton Khirnov <anton@khirnov.net>
Tue, 25 Oct 2016 12:48:13 +0000 (14:48 +0200)
Signed-off-by: Anton Khirnov <anton@khirnov.net>
libavfilter/vf_scale_npp.c

index 247baf1..2fb4990 100644 (file)
@@ -337,7 +337,7 @@ static int init_processing_chain(AVFilterContext *ctx, int in_width, int in_heig
     }
 
     if (last_stage < 0)
-        return AVERROR_BUG;
+        return 0;
     ctx->outputs[0]->hw_frames_ctx = av_buffer_ref(s->stages[last_stage].frames_ctx);
     if (!ctx->outputs[0]->hw_frames_ctx)
         return AVERROR(ENOMEM);