diff options
author | Antoine Riard <ariard@student.42.fr> | 2019-07-15 18:20:12 -0400 |
---|---|---|
committer | Antoine Riard <ariard@student.42.fr> | 2020-04-30 14:37:21 -0400 |
commit | de13363a472ea30dff2f8f55c6ae572281115380 (patch) | |
tree | 7e220b1927512f48b0c39d6c0120e6e99e22074b /src/wallet/wallet.h | |
parent | b855592d835bf4b3fb1263b88d4f96669a1722b1 (diff) | |
download | bitcoin-de13363a472ea30dff2f8f55c6ae572281115380.tar.xz |
[wallet] Move getBlockHeight from Chain::Lock interface to simple Chain
Add HaveChain to assert chain access for wallet-tool in LoadToWallet.
Diffstat (limited to 'src/wallet/wallet.h')
-rw-r--r-- | src/wallet/wallet.h | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/src/wallet/wallet.h b/src/wallet/wallet.h index 662f5d4bb3..fa2821dfea 100644 --- a/src/wallet/wallet.h +++ b/src/wallet/wallet.h @@ -778,6 +778,9 @@ public: /** Interface to assert chain access and if successful lock it */ std::unique_ptr<interfaces::Chain::Lock> LockChain() { return m_chain ? m_chain->lock() : nullptr; } + /** Interface to assert chain access */ + bool HaveChain() const { return m_chain ? true : false; } + std::map<uint256, CWalletTx> mapWallet GUARDED_BY(cs_wallet); typedef std::multimap<int64_t, CWalletTx*> TxItems; |