Skip to content

Commit

Permalink
Merge pull request #40 from LanXuage/fix-socks_waitgroup_invalid
Browse files Browse the repository at this point in the history
修复cmd/socks启动WaitGroup等待失败问题。
  • Loading branch information
shimmeris authored Mar 1, 2023
2 parents 7ff3daf + 8e965f8 commit ec957b8
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion cmd/socks.go
Original file line number Diff line number Diff line change
Expand Up @@ -26,8 +26,8 @@ var socksCmd = &cobra.Command{
key := randomString(socks.KeyLength)

var wg sync.WaitGroup
wg.Add(1)
go func() {
wg.Add(1)
defer wg.Done()
socks.Serve(lp, sp, key)
}()
Expand Down

0 comments on commit ec957b8

Please sign in to comment.