From 201e19f81f558693e0c35bf976bff9f162dbe098 Mon Sep 17 00:00:00 2001 From: Dylan Ratcliffe Date: Sat, 7 Dec 2024 14:52:49 +0000 Subject: [PATCH] Don't exit when the context is cancelled If we do this, it means we close the goroutine that receives on the `errChan` which leaves deadlocked goroutines hanging around forever --- querytracker.go | 3 --- 1 file changed, 3 deletions(-) diff --git a/querytracker.go b/querytracker.go index 40b1e0f..d8dc59e 100644 --- a/querytracker.go +++ b/querytracker.go @@ -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 {