aboutsummaryrefslogtreecommitdiff
path: root/src/wallet/wallet.cpp
diff options
context:
space:
mode:
authorPatrick Strateman <patrick.strateman@gmail.com>2016-11-26 19:32:30 -0800
committerPatrick Strateman <patrick.strateman@gmail.com>2016-12-21 13:49:48 -0800
commitd63ff6265b0c6ae30efcbb9120d4db419606198a (patch)
treea9ea9ba1bcc85f854b6164d8e9689a95eaf5bc15 /src/wallet/wallet.cpp
parent76fec09d878d6dbf214bdb6228d480bd9195db4c (diff)
downloadbitcoin-d63ff6265b0c6ae30efcbb9120d4db419606198a.tar.xz
Make nWalletDBUpdated atomic to avoid a potential race.
Diffstat (limited to 'src/wallet/wallet.cpp')
-rw-r--r--src/wallet/wallet.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/wallet/wallet.cpp b/src/wallet/wallet.cpp
index 39c4fc3f1b..15001776f1 100644
--- a/src/wallet/wallet.cpp
+++ b/src/wallet/wallet.cpp
@@ -3508,7 +3508,7 @@ bool CWallet::InitLoadWallet()
walletInstance->ScanForWalletTransactions(pindexRescan, true);
LogPrintf(" rescan %15dms\n", GetTimeMillis() - nStart);
walletInstance->SetBestChain(chainActive.GetLocator());
- nWalletDBUpdated++;
+ CWalletDB::IncrementUpdateCounter();
// Restore wallet transaction metadata after -zapwallettxes=1
if (GetBoolArg("-zapwallettxes", false) && GetArg("-zapwallettxes", "1") != "2")