etcd: we should trust people

This commit is contained in:
Xiang Li 2014-08-08 18:52:10 -07:00 committed by Yicheng Qin
parent 55c4a3307d
commit 3af8c7da3c
2 changed files with 1 additions and 4 deletions

View File

@ -115,9 +115,6 @@ func (s *Server) SetTick(tick time.Duration) {
// Stop stops the server elegently. // Stop stops the server elegently.
func (s *Server) Stop() { func (s *Server) Stop() {
if s.mode.Get() == stopMode {
return
}
s.mu.Lock() s.mu.Lock()
s.stopped = true s.stopped = true
switch s.mode.Get() { switch s.mode.Get() {

View File

@ -190,7 +190,7 @@ func buildServer(t *testing.T, c *config.Config, id int64) (e *Server, h *httpte
break break
} }
if err != nil { if err != nil {
destroyServer(t, e, h) h.Close()
return nil, nil, err return nil, nil, err
} }
time.Sleep(10 * time.Millisecond) time.Sleep(10 * time.Millisecond)