How to fix negative WaitGroup counter

You’re adding to wgAllScan here:

What’s the len(ports) the 2nd time?