From efa6cf87727af2591f0215a43a8139888256c643 Mon Sep 17 00:00:00 2001 From: Mike Gaffney Date: Sun, 9 Jun 2024 18:46:10 -0700 Subject: [PATCH] Moved wg increment for the return function --- processor.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/processor.go b/processor.go index 603472c..8225736 100644 --- a/processor.go +++ b/processor.go @@ -182,12 +182,12 @@ func (p *Processor[AC, OC, JC]) Exec(ctx context.Context, r *Run[OC, JC]) error } // wgReturn := sync.WaitGroup{} - wg.Add(1) // Now we gotta kick off all of the states to their correct queue p.enqueueAllJobs(r) // Make a central processor and start it + wg.Add(1) go func() { for rtn := range p.returnChan { j := rtn.Job