Skip to content

Commit

Permalink
[Trivial] Pass hash by const ref to CBlockPolicyEstimator::removeTx
Browse files Browse the repository at this point in the history
  • Loading branch information
random-zebra committed Jul 8, 2021
1 parent 7be33e0 commit 33c9aa1
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion src/policy/fees.cpp
Expand Up @@ -280,7 +280,7 @@ void TxConfirmStats::removeTx(unsigned int entryHeight, unsigned int nBestSeenHe
}
}

bool CBlockPolicyEstimator::removeTx(uint256 hash)
bool CBlockPolicyEstimator::removeTx(const uint256& hash)
{
std::map<uint256, TxStatsInfo>::iterator pos = mapMemPoolTxs.find(hash);
if (pos != mapMemPoolTxs.end()) {
Expand Down
2 changes: 1 addition & 1 deletion src/policy/fees.h
Expand Up @@ -214,7 +214,7 @@ class CBlockPolicyEstimator
void processTransaction(const CTxMemPoolEntry& entry, bool fCurrentEstimate);

/** Remove a transaction from the mempool tracking stats*/
bool removeTx(uint256 hash);
bool removeTx(const uint256& hash);

/** Return a feerate estimate */
CFeeRate estimateFee(int confTarget);
Expand Down

0 comments on commit 33c9aa1

Please sign in to comment.