aboutsummaryrefslogtreecommitdiff
path: root/src/main.cpp
diff options
context:
space:
mode:
authorPieter Wuille <[email protected]>2016-02-10 15:47:06 +0100
committerPieter Wuille <[email protected]>2016-02-10 17:11:13 +0100
commite4eebb604e19f67b0c7a483b1ded1229d75ecdd3 (patch)
tree106612ecd02e354ac6924b6fb19a04b917b35144 /src/main.cpp
parentMerge #7490: tests: Remove May15 test (diff)
downloaddiscoin-e4eebb604e19f67b0c7a483b1ded1229d75ecdd3.tar.xz
discoin-e4eebb604e19f67b0c7a483b1ded1229d75ecdd3.zip
Update the wallet best block marker when pruning
Diffstat (limited to 'src/main.cpp')
-rw-r--r--src/main.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/main.cpp b/src/main.cpp
index 20539c1ba..3ad2979b6 100644
--- a/src/main.cpp
+++ b/src/main.cpp
@@ -2262,7 +2262,7 @@ bool static FlushStateToDisk(CValidationState &state, FlushStateMode mode) {
return AbortNode(state, "Failed to write to coin database");
nLastFlush = nNow;
}
- if ((mode == FLUSH_STATE_ALWAYS || mode == FLUSH_STATE_PERIODIC) && nNow > nLastSetChain + (int64_t)DATABASE_WRITE_INTERVAL * 1000000) {
+ if (fDoFullFlush || ((mode == FLUSH_STATE_ALWAYS || mode == FLUSH_STATE_PERIODIC) && nNow > nLastSetChain + (int64_t)DATABASE_WRITE_INTERVAL * 1000000)) {
// Update best block in wallet (so we can detect restored wallets).
GetMainSignals().SetBestChain(chainActive.GetLocator());
nLastSetChain = nNow;