Parse sweep+consolidation intervals on startup, add consolidationinterval config option, change consolidation interval default to 25, only validate consolidatesaplingaddress if consolidation is enabled

This commit is contained in:
Duke Leto
2022-09-11 21:56:21 -04:00
parent 9347b1fa12
commit 5b15d790f9
5 changed files with 54 additions and 57 deletions

View File

@@ -284,12 +284,7 @@ bool AsyncRPCOperation_sweep::main_impl() {
}
if (sweepComplete) {
int sweepInterval = GetArg("-zsweepinterval", 10);
if (sweepInterval < 5) {
fprintf(stderr,"%s: Invalid sweep interval of %d, setting to default of 10\n", __func__, sweepInterval);
sweepInterval = 10;
}
pwalletMain->nextSweep = sweepInterval + chainActive.Tip()->GetHeight();
pwalletMain->nextSweep = pwalletMain->sweepInterval + chainActive.Tip()->GetHeight();
pwalletMain->fSweepRunning = false;
}