refactor: remove CTxMemPool::queryHashes()

Its only usage can easily be replaced with CTxMemPool::entryAll()
This commit is contained in:
stickies-v
2024-01-17 12:51:08 +00:00
parent c818607ed5
commit 282b12ddb0
4 changed files with 5 additions and 23 deletions

View File

@@ -803,19 +803,6 @@ std::vector<CTxMemPool::indexed_transaction_set::const_iterator> CTxMemPool::Get
return iters;
}
void CTxMemPool::queryHashes(std::vector<uint256>& vtxid) const
{
LOCK(cs);
auto iters = GetSortedDepthAndScore();
vtxid.clear();
vtxid.reserve(mapTx.size());
for (auto it : iters) {
vtxid.push_back(it->GetTx().GetHash());
}
}
static TxMempoolInfo GetInfo(CTxMemPool::indexed_transaction_set::const_iterator it) {
return TxMempoolInfo{it->GetSharedTx(), it->GetTime(), it->GetFee(), it->GetTxSize(), it->GetModifiedFee() - it->GetFee()};
}