Reverted locking change in miner.

This should have been done in the original PR but was overlooked.
This commit is contained in:
Tim Flynn 2016-08-16 23:37:30 -04:00
parent c4dfc7a1e2
commit 63c3580a7d

View File

@ -123,7 +123,7 @@ CBlockTemplate* CreateNewBlock(const CChainParams& chainparams, const CScript& s
CAmount nFees = 0;
{
LOCK(cs_main);
LOCK2(cs_main, mempool.cs);
CBlockIndex* pindexPrev = chainActive.Tip();
const int nHeight = pindexPrev->nHeight + 1;
pblock->nTime = GetAdjustedTime();
@ -144,8 +144,6 @@ CBlockTemplate* CreateNewBlock(const CChainParams& chainparams, const CScript& s
: pblock->GetBlockTime();
{
LOCK(mempool.cs);
bool fPriorityBlock = nBlockPrioritySize > 0;
if (fPriorityBlock) {
vecPriority.reserve(mempool.mapTx.size());
@ -276,10 +274,7 @@ CBlockTemplate* CreateNewBlock(const CChainParams& chainparams, const CScript& s
}
}
}
}
// DASH : Masternode and general budget payments
DBG( printf("CreateNewBlock 1\n"); );
// Masternode and general budget payments
FillBlockPayee(txNew, nFees);
// Make payee