Skip to content

Commit

Permalink
Don't exit when the context is cancelled
Browse files Browse the repository at this point in the history
If we do this, it means we close the goroutine that receives on the `errChan` which leaves deadlocked goroutines hanging around forever
  • Loading branch information
dylanratcliffe committed Dec 7, 2024
1 parent 855243b commit 201e19f
Showing 1 changed file with 0 additions and 3 deletions.
3 changes: 0 additions & 3 deletions querytracker.go
Original file line number Diff line number Diff line change
Expand Up @@ -95,9 +95,6 @@ func (qt *QueryTracker) Execute(ctx context.Context) ([]*sdp.Item, []*sdp.QueryE
} else {
errs = nil
}
case <-ctx.Done():
// If the context is closed, return an error
return sdpItems, sdpErrs, ctx.Err()
}

if items == nil && errs == nil {
Expand Down

0 comments on commit 201e19f

Please sign in to comment.