Skip to content

Commit f9e8e57

Browse files
committed
mempool: Improve comments for [GS]etLoadTried
Also change the param name for SetLoadTried to load_tried.
1 parent 813962d commit f9e8e57

File tree

2 files changed

+11
-5
lines changed

2 files changed

+11
-5
lines changed

src/txmempool.cpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1216,8 +1216,8 @@ bool CTxMemPool::GetLoadTried() const
12161216
return m_load_tried;
12171217
}
12181218

1219-
void CTxMemPool::SetLoadTried(bool loaded)
1219+
void CTxMemPool::SetLoadTried(bool load_tried)
12201220
{
12211221
LOCK(cs);
1222-
m_load_tried = loaded;
1222+
m_load_tried = load_tried;
12231223
}

src/txmempool.h

Lines changed: 9 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -728,11 +728,17 @@ class CTxMemPool
728728
*/
729729
void GetTransactionAncestry(const uint256& txid, size_t& ancestors, size_t& descendants, size_t* ancestorsize = nullptr, CAmount* ancestorfees = nullptr) const;
730730

731-
/** @returns true if the mempool is fully loaded */
731+
/**
732+
* @returns true if we've made an attempt to load the mempool regardless of
733+
* whether the attempt was successful or not
734+
*/
732735
bool GetLoadTried() const;
733736

734-
/** Sets the current loaded state */
735-
void SetLoadTried(bool loaded);
737+
/**
738+
* Set whether or not we've made an attempt to load the mempool (regardless
739+
* of whether the attempt was successful or not)
740+
*/
741+
void SetLoadTried(bool load_tried);
736742

737743
unsigned long size() const
738744
{

0 commit comments

Comments
 (0)