Add rewind logic to deal with post-fork software updates

Includes logic for dealing with pruning by Suhas Daftuar.
This commit is contained in:
Pieter Wuille
2016-03-18 17:20:12 +01:00
committed by Jack Grigg
parent f52da91139
commit 89f20450c2
4 changed files with 122 additions and 15 deletions

View File

@@ -94,6 +94,8 @@ enum BlockStatus: uint32_t {
BLOCK_FAILED_VALID = 32, //! stage after last reached validness failed
BLOCK_FAILED_CHILD = 64, //! descends from failed block
BLOCK_FAILED_MASK = BLOCK_FAILED_VALID | BLOCK_FAILED_CHILD,
BLOCK_OPT_WITNESS = 128, //! block data in blk*.data was received with a witness-enforcing client
};
/** The block chain is a tree shaped structure starting with the