consensus: fix processing changeview payloads from recovery message
Using view number from the recovery message is just plain wrong, it's gonna be higher than our current view and these messages will be treated as coming from the future, even though they have their original view number included.
This commit is contained in:
parent
76f71ab1ef
commit
edd60e656e
1 changed files with 1 additions and 0 deletions
|
@ -234,6 +234,7 @@ func (m *recoveryMessage) GetChangeViews(p payload.ConsensusPayload, validators
|
|||
newViewNumber: cv.OriginalViewNumber + 1,
|
||||
timestamp: cv.Timestamp,
|
||||
})
|
||||
c.message.ViewNumber = cv.OriginalViewNumber
|
||||
c.SetValidatorIndex(cv.ValidatorIndex)
|
||||
c.Witness.InvocationScript = cv.InvocationScript
|
||||
c.Witness.VerificationScript = getVerificationScript(cv.ValidatorIndex, validators)
|
||||
|
|
Loading…
Reference in a new issue