mirror of
https://github.com/fluencelabs/tendermint
synced 2025-05-16 16:41:20 +00:00
catchup replay fix
This commit is contained in:
parent
c0024cc7b2
commit
fe660580a4
@ -24,7 +24,7 @@ func (cs *ConsensusState) readReplayMessage(msgBytes []byte, newStepCh chan inte
|
|||||||
var msg ConsensusLogMessage
|
var msg ConsensusLogMessage
|
||||||
wire.ReadJSON(&msg, msgBytes, &err)
|
wire.ReadJSON(&msg, msgBytes, &err)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
fmt.Println(string(msgBytes))
|
fmt.Println("MsgBytes:", msgBytes, string(msgBytes))
|
||||||
return fmt.Errorf("Error reading json data: %v", err)
|
return fmt.Errorf("Error reading json data: %v", err)
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -127,6 +127,8 @@ func (cs *ConsensusState) catchupReplay(height int) error {
|
|||||||
return err
|
return err
|
||||||
} else if len(msgBytes) == 0 {
|
} else if len(msgBytes) == 0 {
|
||||||
continue
|
continue
|
||||||
|
} else if len(msgBytes) == 1 && msgBytes[0] == '\n' {
|
||||||
|
continue
|
||||||
}
|
}
|
||||||
// the first msg is (usually) the NewHeight event, so we can ignore it
|
// the first msg is (usually) the NewHeight event, so we can ignore it
|
||||||
if !beginning && i == 1 {
|
if !beginning && i == 1 {
|
||||||
|
Loading…
x
Reference in New Issue
Block a user