aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorpracticalswift <[email protected]>2019-05-16 11:45:32 +0200
committerpracticalswift <[email protected]>2019-05-17 13:29:04 +0200
commit3a809446b3881e1a6853da78cccf42643c9a5927 (patch)
treecc16f18732842158c75e549b986b5ca10984c86e
parentMove LockAnnotation from threadsafety.h (imported code) to sync.h (our code) (diff)
downloaddiscoin-3a809446b3881e1a6853da78cccf42643c9a5927.tar.xz
discoin-3a809446b3881e1a6853da78cccf42643c9a5927.zip
Move LockAnnotation to make it reflect the truth
-rw-r--r--src/wallet/test/wallet_tests.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/wallet/test/wallet_tests.cpp b/src/wallet/test/wallet_tests.cpp
index 62630c011..b230000a9 100644
--- a/src/wallet/test/wallet_tests.cpp
+++ b/src/wallet/test/wallet_tests.cpp
@@ -272,8 +272,8 @@ static int64_t AddTx(CWallet& wallet, uint32_t lockTime, int64_t mockTime, int64
SetMockTime(mockTime);
CBlockIndex* block = nullptr;
if (blockTime > 0) {
- LockAnnotation lock(::cs_main);
auto locked_chain = wallet.chain().lock();
+ LockAnnotation lock(::cs_main);
auto inserted = mapBlockIndex.emplace(GetRandHash(), new CBlockIndex);
assert(inserted.second);
const uint256& hash = inserted.first->first;