diff options
Diffstat (limited to 'src/validation.h')
-rw-r--r-- | src/validation.h | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/src/validation.h b/src/validation.h index b1b6689c46..64217e6a11 100644 --- a/src/validation.h +++ b/src/validation.h @@ -340,6 +340,12 @@ bool TestBlockValidity(BlockValidationState& state, bool fCheckPOW = true, bool fCheckMerkleRoot = true) EXCLUSIVE_LOCKS_REQUIRED(cs_main); +/** Check with the proof of work on each blockheader matches the value in nBits */ +bool HasValidProofOfWork(const std::vector<CBlockHeader>& headers, const Consensus::Params& consensusParams); + +/** Return the sum of the work on a given set of headers */ +arith_uint256 CalculateHeadersWork(const std::vector<CBlockHeader>& headers); + /** RAII wrapper for VerifyDB: Verify consistency of the block and coin databases */ class CVerifyDB { public: |