Skip to content

Commit 27f176b

Browse files
markya0616alanchchen
authored andcommitted
consensus/istanbul: only send round change message only if we've already been waiting for round change
1 parent 47677df commit 27f176b

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

consensus/istanbul/core/roundchange.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -103,7 +103,7 @@ func (c *core) handleRoundChange(msg *message, src istanbul.Validator) error {
103103
// Once we received f+1 round change messages, those messages form a weak certificate.
104104
// If our round number is smaller than the certificate's round number, we would
105105
// try to catch up the round number.
106-
if num == int(c.valSet.F()+1) {
106+
if c.waitingForRoundChange && num == int(c.valSet.F()+1) {
107107
if cv.Round.Cmp(rc.Round) < 0 {
108108
c.sendRoundChange(rc.Round)
109109
}

0 commit comments

Comments
 (0)