diff options
author | Jorge Timón <jtimon@jtimon.cc> | 2015-02-15 02:21:42 +0100 |
---|---|---|
committer | Jorge Timón <jtimon@jtimon.cc> | 2015-03-26 00:47:51 +0100 |
commit | d698ef690f62c08676dcf9ddc0988e23aa81cbff (patch) | |
tree | d2c52a3b81167039a3991b0809c958862752a8de /src/miner.cpp | |
parent | bd006110fb51f1fc0cbbeef3ed6eaae66b296d8c (diff) |
Consensus: Refactor: Decouple pow.o from chainparams.o
Diffstat (limited to 'src/miner.cpp')
-rw-r--r-- | src/miner.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/miner.cpp b/src/miner.cpp index 01212b19c4..cf08b78229 100644 --- a/src/miner.cpp +++ b/src/miner.cpp @@ -84,7 +84,7 @@ void UpdateTime(CBlockHeader* pblock, const CBlockIndex* pindexPrev) // Updating time can change work required on testnet: if (Params().AllowMinDifficultyBlocks()) - pblock->nBits = GetNextWorkRequired(pindexPrev, pblock); + pblock->nBits = GetNextWorkRequired(pindexPrev, pblock, Params().GetConsensus()); } CBlockTemplate* CreateNewBlock(const CScript& scriptPubKeyIn) @@ -326,7 +326,7 @@ CBlockTemplate* CreateNewBlock(const CScript& scriptPubKeyIn) // Fill in header pblock->hashPrevBlock = pindexPrev->GetBlockHash(); UpdateTime(pblock, pindexPrev); - pblock->nBits = GetNextWorkRequired(pindexPrev, pblock); + pblock->nBits = GetNextWorkRequired(pindexPrev, pblock, Params().GetConsensus()); pblock->nNonce = 0; pblocktemplate->vTxSigOps[0] = GetLegacySigOpCount(pblock->vtx[0]); |