mirror of
https://github.com/ElementsProject/elements.git
synced 2026-08-16 13:01:19 +02:00
Consensus: Refactor: Decouple pow.o from chainparams.o
This commit is contained in:
parent
bd006110fb
commit
d698ef690f
8 changed files with 42 additions and 35 deletions
|
|
@ -5,6 +5,8 @@
|
|||
|
||||
#include "txdb.h"
|
||||
|
||||
#include "chainparams.h"
|
||||
#include "hash.h"
|
||||
#include "main.h"
|
||||
#include "pow.h"
|
||||
#include "uint256.h"
|
||||
|
|
@ -223,7 +225,7 @@ bool CBlockTreeDB::LoadBlockIndexGuts()
|
|||
pindexNew->nStatus = diskindex.nStatus;
|
||||
pindexNew->nTx = diskindex.nTx;
|
||||
|
||||
if (!CheckProofOfWork(pindexNew->GetBlockHash(), pindexNew->nBits))
|
||||
if (!CheckProofOfWork(pindexNew->GetBlockHash(), pindexNew->nBits, Params().GetConsensus()))
|
||||
return error("LoadBlockIndex(): CheckProofOfWork failed: %s", pindexNew->ToString());
|
||||
|
||||
pcursor->Next();
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue