Introduced in 4e0eed88acdd41826868c151373068bfad18b84d
When an invalid block is found during a reorg, we know the last of the blocks in the was-to-be-connected chain is invalid, but not necessarily the first. As `vpIndexToConnect` is ordered in decreasing height, the end of the reorg is the front of the vector, and not the back.
This only affected the warning system.
You can view, comment on, or merge this pull request online at:
— Commit Summary —
* Bugfix: the end of a reorged chain is invalid when connect fails
— File Changes —
M src/validation.cpp (5)
— Patch Links —