]> Git Repo - VerusCoin.git/commit
Prepare block connection logic for headers-first.
authorPieter Wuille <[email protected]>
Sat, 16 Nov 2013 18:28:24 +0000 (19:28 +0100)
committerPieter Wuille <[email protected]>
Mon, 27 Jan 2014 20:20:41 +0000 (21:20 +0100)
commit75f51f2a63e0ebe34ab290c2b7141dd240b98c3b
treeed9be9e3acbcd9d9df9f67264042109b8cd7db98
parent0ec16f35d6b8d9f1fe876f1405f105f6e5aa0933
Prepare block connection logic for headers-first.

This changes the block processing logic from "try to atomically switch
to a new block" to a continuous "(dis)connect a block, aiming for the
assumed best chain".

This means the smallest atomic operations on the chainstate become
individual block connections or disconnections, instead of entire
reorganizations. It may mean that we try to reorganize to one block,
fail, and rereorganize again to the old block. This is slower, but
doesn't require unbounded RAM.

It also means that a ConnectBlock which fails may be no longer called
from the ProcessBlock which knows which node sent it. To deal with that,
a mapBlockSource is kept, and invalid blocks cause asynchronous "reject"
messages and banning (if necessary).
src/init.cpp
src/main.cpp
src/main.h
This page took 0.036857 seconds and 4 git commands to generate.