Fix go routine leak in auto encrypt ca roots tracking

This commit is contained in:
Matt Keeler 2020-06-24 12:38:56 -04:00
parent 25a4f3c83b
commit 29d0cfdd7d
No known key found for this signature in database
GPG Key ID: 04DBAE1857E0081B

View File

@ -640,6 +640,7 @@ func (s *Server) trackAutoEncryptCARoots() {
ws := memdb.NewWatchSet()
state := s.fsm.State()
ws.Add(state.AbandonCh())
ws.Add(s.shutdownCh)
_, cas, err := state.CARoots(ws)
if err != nil {
s.logger.Error("Failed to watch AutoEncrypt CARoot", "error", err)