MCPcopy Create free account
hub / github.com/bitcoinxt/bitcoinxt / removeUnchecked

Method removeUnchecked

src/txmempool.cpp:450–463  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

448}
449
450void CTxMemPool::removeUnchecked(txiter it)
451{
452 const uint256 hash = it->GetTx().GetHash();
453 BOOST_FOREACH(const CTxIn& txin, it->GetTx().vin)
454 mapNextTx.erase(txin.prevout);
455
456 totalTxSize -= it->GetTxSize();
457 cachedInnerUsage -= it->DynamicMemoryUsage();
458 cachedInnerUsage -= memusage::DynamicUsage(mapLinks[it].parents) + memusage::DynamicUsage(mapLinks[it].children);
459 mapLinks.erase(it);
460 mapTx.erase(it);
461 nTransactionsUpdated++;
462 minerPolicyEstimator->removeTx(hash);
463}
464
465// Calculates descendants of entry that are not already in setDescendants, and adds to
466// setDescendants. Assumes entryit is already a tx in the mempool and setMemPoolChildren

Callers

nothing calls this directly

Calls 6

DynamicUsageFunction · 0.85
GetTxSizeMethod · 0.80
removeTxMethod · 0.80
GetHashMethod · 0.45
eraseMethod · 0.45
DynamicMemoryUsageMethod · 0.45

Tested by

no test coverage detected