mirror of
https://github.com/serai-dex/serai.git
synced 2025-12-11 05:29:25 +00:00
Correct time-adjustment code on round skip
This commit is contained in:
@@ -213,13 +213,14 @@ impl<N: Network + 'static> TendermintMachine<N> {
|
|||||||
let end = self.timeout(Step::Precommit);
|
let end = self.timeout(Step::Precommit);
|
||||||
self.end_time.insert(Round(r), end);
|
self.end_time.insert(Round(r), end);
|
||||||
self.start_time = end;
|
self.start_time = end;
|
||||||
|
self.round.0 += 1;
|
||||||
}
|
}
|
||||||
|
debug_assert_eq!(self.round, round);
|
||||||
|
|
||||||
// 11-13
|
// 11-13
|
||||||
// Clear timeouts
|
// Clear timeouts
|
||||||
self.timeouts = HashMap::new();
|
self.timeouts = HashMap::new();
|
||||||
|
|
||||||
self.round = round;
|
|
||||||
self.end_time.insert(round, self.timeout(Step::Precommit));
|
self.end_time.insert(round, self.timeout(Step::Precommit));
|
||||||
self.step = Step::Propose;
|
self.step = Step::Propose;
|
||||||
self.round_propose()
|
self.round_propose()
|
||||||
|
|||||||
Reference in New Issue
Block a user