Removed wg from worker start. Fixed various races.

This commit is contained in:
Jay
2026-04-20 17:54:03 -04:00
parent aaf8571b9f
commit 2c7b22b3d9
8 changed files with 72 additions and 43 deletions
+2 -1
View File
@@ -278,7 +278,8 @@ func (p *Pool) addLocked(id string, socket types.Socket) error {
go func() {
defer cancel()
defer close(peer.done)
worker.Start(pool, &p.wg)
worker.Start(pool)
p.wg.Done()
}()
p.peers[id] = peer