diff --git a/pkg/engine/daemon.go b/pkg/engine/daemon.go index a6d2975a..31f96018 100644 --- a/pkg/engine/daemon.go +++ b/pkg/engine/daemon.go @@ -270,9 +270,8 @@ func (e *Engine) startDaemon(tool types.Tool) (string, error) { _ = resp.Body.Close() }() return url, nil - } else { - _ = resp.Body.Close() } + _ = resp.Body.Close() select { case <-killedCtx.Done(): return url, fmt.Errorf("daemon failed to start: %w", context.Cause(killedCtx))