fix(orchestrator): use labeled break to correctly exit for/select on context cancel (SA4011)
Add tools.go to pin staticcheck as a module dependency so CI installs it from the module cache instead of re-downloading on every run.
This commit is contained in:
@@ -247,10 +247,11 @@ func (o *Orchestrator) Run(ctx context.Context) error {
|
||||
}()
|
||||
|
||||
var bookWG sync.WaitGroup
|
||||
bookLoop:
|
||||
for entry := range entries {
|
||||
select {
|
||||
case <-ctx.Done():
|
||||
break
|
||||
break bookLoop
|
||||
default:
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user