txmempool: Remove unused clear() member function

This commit is contained in:
MarcoFalke
2022-12-13 13:07:01 +01:00
parent 6061eb6564
commit fa818e103c
3 changed files with 13 additions and 32 deletions

View File

@@ -389,7 +389,6 @@ CTxMemPool::CTxMemPool(const Options& opts)
m_full_rbf{opts.full_rbf},
m_limits{opts.limits}
{
_clear(); //lock free clear
}
bool CTxMemPool::isSpent(const COutPoint& outpoint) const
@@ -627,26 +626,6 @@ void CTxMemPool::removeForBlock(const std::vector<CTransactionRef>& vtx, unsigne
blockSinceLastRollingFeeBump = true;
}
void CTxMemPool::_clear()
{
vTxHashes.clear();
mapTx.clear();
mapNextTx.clear();
totalTxSize = 0;
m_total_fee = 0;
cachedInnerUsage = 0;
lastRollingFeeUpdate = GetTime();
blockSinceLastRollingFeeBump = false;
rollingMinimumFeeRate = 0;
++nTransactionsUpdated;
}
void CTxMemPool::clear()
{
LOCK(cs);
_clear();
}
void CTxMemPool::check(const CCoinsViewCache& active_coins_tip, int64_t spendheight) const
{
if (m_check_ratio == 0) return;