mirror of
https://github.com/bitcoin/bitcoin.git
synced 2025-11-10 22:18:54 +01:00
validation: move UpdateUncommittedBlockStructures and GenerateCoinbaseCommitment into ChainstateManager
This commit is contained in:
@@ -362,12 +362,6 @@ bool TestBlockValidity(BlockValidationState& state,
|
||||
bool fCheckPOW = true,
|
||||
bool fCheckMerkleRoot = true) EXCLUSIVE_LOCKS_REQUIRED(cs_main);
|
||||
|
||||
/** Update uncommitted block structures (currently: only the witness reserved value). This is safe for submitted blocks. */
|
||||
void UpdateUncommittedBlockStructures(CBlock& block, const CBlockIndex* pindexPrev, const Consensus::Params& consensusParams);
|
||||
|
||||
/** Produce the necessary coinbase commitment for a block (modifies the hash, don't call for mined blocks). */
|
||||
std::vector<unsigned char> GenerateCoinbaseCommitment(CBlock& block, const CBlockIndex* pindexPrev, const Consensus::Params& consensusParams);
|
||||
|
||||
/** RAII wrapper for VerifyDB: Verify consistency of the block and coin databases */
|
||||
class CVerifyDB {
|
||||
public:
|
||||
@@ -1000,6 +994,12 @@ public:
|
||||
//! ResizeCoinsCaches() as needed.
|
||||
void MaybeRebalanceCaches() EXCLUSIVE_LOCKS_REQUIRED(::cs_main);
|
||||
|
||||
/** Update uncommitted block structures (currently: only the witness reserved value). This is safe for submitted blocks. */
|
||||
void UpdateUncommittedBlockStructures(CBlock& block, const CBlockIndex* pindexPrev) const;
|
||||
|
||||
/** Produce the necessary coinbase commitment for a block (modifies the hash, don't call for mined blocks). */
|
||||
std::vector<unsigned char> GenerateCoinbaseCommitment(CBlock& block, const CBlockIndex* pindexPrev) const;
|
||||
|
||||
~ChainstateManager();
|
||||
};
|
||||
|
||||
|
||||
Reference in New Issue
Block a user