From 563faa98de64b258bf58c5ec0c917a6fc9cda47f Mon Sep 17 00:00:00 2001 From: Zach Ramsay Date: Tue, 3 Oct 2017 18:12:17 -0400 Subject: [PATCH] address comments, pr #643 --- blockchain/pool.go | 2 +- cmd/tendermint/commands/reset_priv_validator.go | 1 + consensus/reactor.go | 2 +- consensus/state.go | 1 + 4 files changed, 4 insertions(+), 2 deletions(-) diff --git a/blockchain/pool.go b/blockchain/pool.go index f4fd1a32b..0791bdb00 100644 --- a/blockchain/pool.go +++ b/blockchain/pool.go @@ -313,7 +313,7 @@ func (pool *BlockPool) makeNextRequester() { _, err := request.Start() if err != nil { - pool.Logger.Error("Error starting block pool", "err", err) + request.Logger.Error("Error starting request", "err", err) } } diff --git a/cmd/tendermint/commands/reset_priv_validator.go b/cmd/tendermint/commands/reset_priv_validator.go index 77407cfcf..1612b89cf 100644 --- a/cmd/tendermint/commands/reset_priv_validator.go +++ b/cmd/tendermint/commands/reset_priv_validator.go @@ -49,6 +49,7 @@ func ResetAll(dbDir, privValFile string, logger log.Logger) { resetPrivValidatorLocal(privValFile, logger) if err := os.RemoveAll(dbDir); err != nil { logger.Error("Error removing directory", "err", err) + return } logger.Info("Removed all data", "dir", dbDir) } diff --git a/consensus/reactor.go b/consensus/reactor.go index 0eaacefdd..e873ddde9 100644 --- a/consensus/reactor.go +++ b/consensus/reactor.go @@ -99,7 +99,7 @@ func (conR *ConsensusReactor) SwitchToConsensus(state *sm.State, blocksSynced in } _, err := conR.conS.Start() if err != nil { - conR.Logger.Error("Error starting conR", "err", err) + conR.Logger.Error("Error starting conS", "err", err) } } diff --git a/consensus/state.go b/consensus/state.go index c50e431e1..2c2b5d1f4 100644 --- a/consensus/state.go +++ b/consensus/state.go @@ -260,6 +260,7 @@ func (cs *ConsensusState) startRoutines(maxSteps int) { _, err := cs.timeoutTicker.Start() if err != nil { cs.Logger.Error("Error starting timeout ticker", "err", err) + return } go cs.receiveRoutine(maxSteps) }