From 9d1dfcbfc02b4a00a50e7dd63f8fd61203fb25fa Mon Sep 17 00:00:00 2001 From: Liam Girdwood Date: Fri, 8 Dec 2017 22:41:31 +0000 Subject: [PATCH] pipeline: make sure pipeline_down steam returns correct value pipeline_copy down stream will return 0 instead of the component copy() return value when an endpoint is reached. Make sure we return the component value. Signed-off-by: Liam Girdwood --- src/audio/pipeline.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/audio/pipeline.c b/src/audio/pipeline.c index ccd60943b..4fe7896fe 100644 --- a/src/audio/pipeline.c +++ b/src/audio/pipeline.c @@ -789,7 +789,7 @@ static int pipeline_copy_to_downstream(struct comp_dev *start, /* stop going downstream if we reach an end point in this pipeline */ if (current->is_endpoint) - return 0; + goto out; } /* travel downstream to sink end point(s) */ @@ -815,6 +815,7 @@ static int pipeline_copy_to_downstream(struct comp_dev *start, } } +out: /* return back upstream */ tracev_pipe("CD-"); return err;