We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 7b87f63 commit 59105aaCopy full SHA for 59105aa
pkg/media/pipeline.go
@@ -203,7 +203,9 @@ func (p *Pipeline) Run(ctx context.Context) error {
203
// Return the error from the most upstream part of the pipeline
204
err = p.input.Close()
205
sinkErr := p.sink.Close()
206
- if err == nil {
+
207
+ if err == nil || (err == context.Canceled && sinkErr != nil) {
208
+ // prefer sink error if exists (causal and more specific) over the generic context.Canceled error
209
err = sinkErr
210
}
211
0 commit comments