Skip to content

Commit 0000d8f

Browse files
Document how FlushStateMode::NONE is handled
1 parent 2311c7c commit 0000d8f

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

src/validation.cpp

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2064,6 +2064,9 @@ bool CChainState::ConnectBlock(const CBlock& block, CValidationState& state, CBl
20642064
* The caches and indexes are flushed depending on the mode we're called with
20652065
* if they're too large, if it's been a while since the last write,
20662066
* or always and in all cases if we're in prune mode and are deleting files.
2067+
*
2068+
* If FlushStateMode::NONE is used, then FlushStateToDisk(...) won't do anything
2069+
* besides checking if we need to prune.
20672070
*/
20682071
bool static FlushStateToDisk(const CChainParams& chainparams, CValidationState &state, FlushStateMode mode, int nManualPruneHeight) {
20692072
int64_t nMempoolUsage = mempool.DynamicMemoryUsage();

0 commit comments

Comments
 (0)