consensus: fix negative timeout; log levels

This commit is contained in:
Ethan Buchman
2015-12-15 14:44:58 -05:00
parent c95b89e98c
commit c3a8f202ab
2 changed files with 10 additions and 6 deletions

View File

@ -283,15 +283,14 @@ func (conR *ConsensusReactor) broadcastHasVoteMessage(vote *types.Vote, index in
}
func makeRoundStepMessages(rs *RoundState) (nrsMsg *NewRoundStepMessage, csMsg *CommitStepMessage) {
step := RoundStepType(rs.Step)
nrsMsg = &NewRoundStepMessage{
Height: rs.Height,
Round: rs.Round,
Step: step,
Step: rs.Step,
SecondsSinceStartTime: int(time.Now().Sub(rs.StartTime).Seconds()),
LastCommitRound: rs.LastCommit.Round(),
}
if step == RoundStepCommit {
if rs.Step == RoundStepCommit {
csMsg = &CommitStepMessage{
Height: rs.Height,
BlockPartsHeader: rs.ProposalBlockParts.Header(),