Precompute sighashes
Original version by Nicolas Dorier. Precomputing version by Pieter Wuille. Edited for Zcash by Ariel Gabizon and Jack Grigg
This commit is contained in:
committed by
Jack Grigg
parent
722d811f89
commit
f762d44973
@@ -293,7 +293,8 @@ CBlockTemplate* CreateNewBlock(const CScript& scriptPubKeyIn)
|
||||
// policy here, but we still have to ensure that the block we
|
||||
// create only contains transactions that are valid in new blocks.
|
||||
CValidationState state;
|
||||
if (!ContextualCheckInputs(tx, state, view, true, MANDATORY_SCRIPT_VERIFY_FLAGS, true, Params().GetConsensus()))
|
||||
CachedHashes cachedHashes(tx);
|
||||
if (!ContextualCheckInputs(tx, state, view, true, MANDATORY_SCRIPT_VERIFY_FLAGS, true, cachedHashes, Params().GetConsensus()))
|
||||
continue;
|
||||
|
||||
UpdateCoins(tx, view, nHeight);
|
||||
|
||||
Reference in New Issue
Block a user