It seems the socket.Close() only does sck.reaperCond.Signal() to close connReaper goroutine. But the signal seems can be delivered only if the connReaper is in sck.reaperCond.Wait().
That cause at least short leaving sockets (.Dial() and .Close()) sometimes to leak.
It seems the socket.Close() only does sck.reaperCond.Signal() to close connReaper goroutine. But the signal seems can be delivered only if the connReaper is in sck.reaperCond.Wait().
That cause at least short leaving sockets (.Dial() and .Close()) sometimes to leak.