aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorCarl Dong <contact@carldong.me>2022-07-13 21:24:03 -0400
committerCarl Dong <contact@carldong.me>2022-07-15 11:35:13 -0400
commitf9e8e5719f28d84f68f7d75e26c8e7fccac8e7d3 (patch)
tree3a41dda434a55d277ef0ccaa2e84e22ab2ef48ff
parent813962da0b17b918941c6849996845e35d84a451 (diff)
mempool: Improve comments for [GS]etLoadTried
Also change the param name for SetLoadTried to load_tried.
-rw-r--r--src/txmempool.cpp4
-rw-r--r--src/txmempool.h12
2 files changed, 11 insertions, 5 deletions
diff --git a/src/txmempool.cpp b/src/txmempool.cpp
index 00e3068946..7eff6bdbe3 100644
--- a/src/txmempool.cpp
+++ b/src/txmempool.cpp
@@ -1216,8 +1216,8 @@ bool CTxMemPool::GetLoadTried() const
return m_load_tried;
}
-void CTxMemPool::SetLoadTried(bool loaded)
+void CTxMemPool::SetLoadTried(bool load_tried)
{
LOCK(cs);
- m_load_tried = loaded;
+ m_load_tried = load_tried;
}
diff --git a/src/txmempool.h b/src/txmempool.h
index 1abf641ed2..d7d308038c 100644
--- a/src/txmempool.h
+++ b/src/txmempool.h
@@ -728,11 +728,17 @@ public:
*/
void GetTransactionAncestry(const uint256& txid, size_t& ancestors, size_t& descendants, size_t* ancestorsize = nullptr, CAmount* ancestorfees = nullptr) const;
- /** @returns true if the mempool is fully loaded */
+ /**
+ * @returns true if we've made an attempt to load the mempool regardless of
+ * whether the attempt was successful or not
+ */
bool GetLoadTried() const;
- /** Sets the current loaded state */
- void SetLoadTried(bool loaded);
+ /**
+ * Set whether or not we've made an attempt to load the mempool (regardless
+ * of whether the attempt was successful or not)
+ */
+ void SetLoadTried(bool load_tried);
unsigned long size() const
{