aboutsummaryrefslogtreecommitdiff
path: root/src/main.h
diff options
context:
space:
mode:
authorAlex Morcos <morcos@chaincode.com>2015-11-03 10:35:39 -0500
committerAlex Morcos <morcos@chaincode.com>2015-12-01 12:09:37 -0500
commit553cad94e29c33872b60d97b8574ed2773355f0b (patch)
tree0cf289e53969878180a50a36cb264e084b0179f6 /src/main.h
parent5f122633020ce5d9f78c73394cda576a8657a3ac (diff)
downloadbitcoin-553cad94e29c33872b60d97b8574ed2773355f0b.tar.xz
Rewrite CreateNewBlock
Use the score index on the mempool to only add sorted txs in order. Remove much of the validation while building the block, relying on mempool to be consistent and only contain txs that can be mined. The mempool is assumed to be consistent as far as not containing txs which spend non-existent outputs or double spends, and scripts are valid. Finality of txs is still checked (except not coinbase maturity, assumed in mempool). Still TestBlockValidity in case mempool consistency breaks and return error state if an invalid block was created. Unit tests are modified to realize that invalid blocks can now be constructed if the mempool breaks its consistency assumptions and also updated to have the right fees, since the cached value is now used for block construction. Conflicts: src/miner.cpp
Diffstat (limited to 'src/main.h')
0 files changed, 0 insertions, 0 deletions