diff options
author | marcofleon <marleo23@proton.me> | 2024-05-29 08:53:50 -0700 |
---|---|---|
committer | marcofleon <marleo23@proton.me> | 2024-05-29 09:02:07 -0700 |
commit | 8defc182a31d828ad0f53ebf7e3be9e9cfc42d09 (patch) | |
tree | e3d16eefeb6e29e50d74dc9fc63805ff6e4ecfcf /src | |
parent | 0048680467e15037023ceae44bc2dc8309f82f39 (diff) |
scripted-diff: Replace nNextSweep with m_next_sweep
-BEGIN VERIFY SCRIPT-
sed -i 's/nNextSweep/m_next_sweep/g' $(git grep -l 'nNextSweep')
-END VERIFY SCRIPT-
fixing to match style
Diffstat (limited to 'src')
-rw-r--r-- | src/txorphanage.cpp | 4 | ||||
-rw-r--r-- | src/txorphanage.h | 2 |
2 files changed, 3 insertions, 3 deletions
diff --git a/src/txorphanage.cpp b/src/txorphanage.cpp index cfafadcb98..3eaf53939d 100644 --- a/src/txorphanage.cpp +++ b/src/txorphanage.cpp @@ -120,7 +120,7 @@ void TxOrphanage::LimitOrphans(unsigned int max_orphans, FastRandomContext& rng) unsigned int nEvicted = 0; auto nNow{Now<NodeSeconds>()}; - if (nNextSweep <= nNow) { + if (m_next_sweep <= nNow) { // Sweep out expired orphan pool entries: int nErased = 0; auto nMinExpTime{nNow + ORPHAN_TX_EXPIRE_TIME - ORPHAN_TX_EXPIRE_INTERVAL}; @@ -135,7 +135,7 @@ void TxOrphanage::LimitOrphans(unsigned int max_orphans, FastRandomContext& rng) } } // Sweep again 5 minutes after the next entry that expires in order to batch the linear scan. - nNextSweep = nMinExpTime + ORPHAN_TX_EXPIRE_INTERVAL; + m_next_sweep = nMinExpTime + ORPHAN_TX_EXPIRE_INTERVAL; if (nErased > 0) LogPrint(BCLog::TXPACKAGES, "Erased %d orphan tx due to expiration\n", nErased); } while (m_orphans.size() > max_orphans) diff --git a/src/txorphanage.h b/src/txorphanage.h index 2da8582869..3054396b2d 100644 --- a/src/txorphanage.h +++ b/src/txorphanage.h @@ -107,7 +107,7 @@ protected: int EraseTxNoLock(const Wtxid& wtxid) EXCLUSIVE_LOCKS_REQUIRED(m_mutex); /** Timestamp for the next scheduled sweep of expired orphans */ - NodeSeconds nNextSweep GUARDED_BY(m_mutex){0s}; + NodeSeconds m_next_sweep GUARDED_BY(m_mutex){0s}; }; #endif // BITCOIN_TXORPHANAGE_H |