be sure to exit the go routine if we terminate normally

pull/4233/head
Cory LaNou 2015-09-29 16:32:04 -05:00
parent 7a3e1f6b27
commit 34bfb6b330
1 changed files with 2 additions and 0 deletions

View File

@ -406,6 +406,8 @@ func (s *Server) executeShutdown(c <-chan struct{}) {
os.Exit(1) os.Exit(1)
} }
os.Exit(0) os.Exit(0)
case <-s.closing:
return
} }
} }
} }