rename transition

This commit is contained in:
keorn 2016-11-18 13:37:47 +00:00
parent e90d814193
commit 2f3b801296
1 changed files with 2 additions and 5 deletions

View File

@ -16,7 +16,6 @@
//! Tendermint timeout handling.
use std::sync::atomic::{Ordering as AtomicOrdering};
use std::sync::Weak;
use io::{IoContext, IoHandler, TimerToken};
use super::{Tendermint, Step};
@ -86,14 +85,12 @@ impl IoHandler<Step> for TransitionHandler {
},
Step::Precommit if engine.has_enough_any_votes() => {
set_timeout(io, engine.our_params.timeouts.propose);
engine.round.fetch_add(1, AtomicOrdering::SeqCst);
engine.increment_round(1);
Some(Step::Propose)
},
Step::Commit => {
set_timeout(io, engine.our_params.timeouts.propose);
engine.last_lock.store(0, AtomicOrdering::SeqCst);
engine.round.store(0, AtomicOrdering::SeqCst);
engine.height.fetch_add(1, AtomicOrdering::SeqCst);
engine.reset_round();
Some(Step::Propose)
},
_ => None,