mirror of
https://github.com/fluencelabs/tendermint
synced 2025-04-25 14:52:17 +00:00
minor fix for when the blockstore is ahead by one.
This commit is contained in:
parent
6d6f061f19
commit
dc27d56cc3
@ -46,7 +46,8 @@ type BlockchainReactor struct {
|
|||||||
}
|
}
|
||||||
|
|
||||||
func NewBlockchainReactor(state *sm.State, store *BlockStore, sync bool) *BlockchainReactor {
|
func NewBlockchainReactor(state *sm.State, store *BlockStore, sync bool) *BlockchainReactor {
|
||||||
if state.LastBlockHeight != store.Height() {
|
if state.LastBlockHeight != store.Height() &&
|
||||||
|
state.LastBlockHeight != store.Height()-1 { // XXX double check this logic.
|
||||||
panic(Fmt("state (%v) and store (%v) height mismatch", state.LastBlockHeight, store.Height()))
|
panic(Fmt("state (%v) and store (%v) height mismatch", state.LastBlockHeight, store.Height()))
|
||||||
}
|
}
|
||||||
requestsCh := make(chan BlockRequest, defaultChannelCapacity)
|
requestsCh := make(chan BlockRequest, defaultChannelCapacity)
|
||||||
|
Loading…
x
Reference in New Issue
Block a user