mirror of
https://github.com/etcd-io/etcd.git
synced 2024-09-27 06:25:44 +00:00
fix(server): avoid race conditions in Run/Stop
- don't close ready channel until PeerServer is listening. avoids possible panic in Stop() if PeerServer is nil. - avoid data race in Run() (err variable was shared between 2 goroutines) - avoid data race in PeerServer Start/Stop (PeerServer.closeChan)
This commit is contained in: