mirror of
https://github.com/bitcoin/bitcoin.git
synced 2025-02-12 11:19:08 -05:00
miner: Remove uncompiled MTP code
This commit is contained in:
parent
fa6b7adf96
commit
fa46ac4d9d
2 changed files with 4 additions and 7 deletions
|
@ -134,11 +134,7 @@ std::unique_ptr<CBlockTemplate> BlockAssembler::CreateNewBlock(const CScript& sc
|
||||||
}
|
}
|
||||||
|
|
||||||
pblock->nTime = GetAdjustedTime();
|
pblock->nTime = GetAdjustedTime();
|
||||||
const int64_t nMedianTimePast = pindexPrev->GetMedianTimePast();
|
m_lock_time_cutoff = pindexPrev->GetMedianTimePast();
|
||||||
|
|
||||||
nLockTimeCutoff = (STANDARD_LOCKTIME_VERIFY_FLAGS & LOCKTIME_MEDIAN_TIME_PAST)
|
|
||||||
? nMedianTimePast
|
|
||||||
: pblock->GetBlockTime();
|
|
||||||
|
|
||||||
// Decide whether to include witness transactions
|
// Decide whether to include witness transactions
|
||||||
// This is only needed in case the witness softfork activation is reverted
|
// This is only needed in case the witness softfork activation is reverted
|
||||||
|
@ -223,7 +219,7 @@ bool BlockAssembler::TestPackage(uint64_t packageSize, int64_t packageSigOpsCost
|
||||||
bool BlockAssembler::TestPackageTransactions(const CTxMemPool::setEntries& package) const
|
bool BlockAssembler::TestPackageTransactions(const CTxMemPool::setEntries& package) const
|
||||||
{
|
{
|
||||||
for (CTxMemPool::txiter it : package) {
|
for (CTxMemPool::txiter it : package) {
|
||||||
if (!IsFinalTx(it->GetTx(), nHeight, nLockTimeCutoff)) {
|
if (!IsFinalTx(it->GetTx(), nHeight, m_lock_time_cutoff)) {
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
if (!fIncludeWitness && it->GetTx().HasWitness()) {
|
if (!fIncludeWitness && it->GetTx().HasWitness()) {
|
||||||
|
|
|
@ -144,7 +144,8 @@ private:
|
||||||
|
|
||||||
// Chain context for the block
|
// Chain context for the block
|
||||||
int nHeight;
|
int nHeight;
|
||||||
int64_t nLockTimeCutoff;
|
int64_t m_lock_time_cutoff;
|
||||||
|
|
||||||
const CChainParams& chainparams;
|
const CChainParams& chainparams;
|
||||||
const CTxMemPool& m_mempool;
|
const CTxMemPool& m_mempool;
|
||||||
CChainState& m_chainstate;
|
CChainState& m_chainstate;
|
||||||
|
|
Loading…
Add table
Reference in a new issue