From 26421dd4df2ed9a92b763c9707085a05d6e28479 Mon Sep 17 00:00:00 2001 From: Jitendra Bhurat Date: Wed, 3 Jun 2020 10:31:12 -0400 Subject: [PATCH] Streamline call to newRoundChangeTimer() (#109) --- consensus/qibft/core/handler.go | 3 --- consensus/qibft/core/roundchange.go | 1 - 2 files changed, 4 deletions(-) diff --git a/consensus/qibft/core/handler.go b/consensus/qibft/core/handler.go index 04042d8d5..d9317703c 100644 --- a/consensus/qibft/core/handler.go +++ b/consensus/qibft/core/handler.go @@ -187,9 +187,6 @@ func (c *core) handleTimeoutMsg() { nextRound := new(big.Int).Add(round, common.Big1) c.startNewRound(nextRound) - // Start the timer - c.newRoundChangeTimer() - // Send Round Change c.sendRoundChange(nextRound) } diff --git a/consensus/qibft/core/roundchange.go b/consensus/qibft/core/roundchange.go index 3ca39a1ae..ce3139aef 100644 --- a/consensus/qibft/core/roundchange.go +++ b/consensus/qibft/core/roundchange.go @@ -122,7 +122,6 @@ func (c *core) handleRoundChange(msg *message, src istanbul.Validator) error { newRound := c.roundChangeSet.getMinRoundChange(cv.Round) logger.Trace("Starting new Round", "round", newRound) c.startNewRound(newRound) - c.newRoundChangeTimer() c.sendRoundChange(newRound) } else if currentRoundMessages >= c.QuorumSize() && c.IsProposer() && c.justifyRoundChange(cv.Round) && c.current.preprepareSent.Cmp(cv.Round) < 0 {