diff --git a/src/plz/plz.go b/src/plz/plz.go index 223ac7b65..fac5e036f 100644 --- a/src/plz/plz.go +++ b/src/plz/plz.go @@ -59,7 +59,9 @@ func Run(targets, preTargets []core.BuildLabel, state *core.BuildState, config * }() go func() { for task := range actions { + wg.Add(1) go func(task core.Task) { + defer wg.Done() remote := anyRemote && !task.Target.Local if remote { remoteLimiter.Acquire()