Skip to content

Commit b88b463

Browse files
rjl493456442karalabe
authored andcommitted
core: fix chain indexer unit test (#20506)
1 parent 4c8fcd9 commit b88b463

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

core/chain_indexer_test.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -203,7 +203,7 @@ func (b *testChainIndexBackend) assertBlocks(headNum, failNum uint64) (uint64, b
203203
}
204204

205205
func (b *testChainIndexBackend) reorg(headNum uint64) uint64 {
206-
firstChanged := headNum / b.indexer.sectionSize
206+
firstChanged := (headNum + 1) / b.indexer.sectionSize
207207
if firstChanged < b.stored {
208208
b.stored = firstChanged
209209
}

0 commit comments

Comments
 (0)