aboutsummaryrefslogtreecommitdiff
path: root/src/interfaces
diff options
context:
space:
mode:
Diffstat (limited to 'src/interfaces')
-rw-r--r--src/interfaces/chain.cpp2
-rw-r--r--src/interfaces/chain.h2
-rw-r--r--src/interfaces/node.cpp2
-rw-r--r--src/interfaces/wallet.cpp5
4 files changed, 6 insertions, 5 deletions
diff --git a/src/interfaces/chain.cpp b/src/interfaces/chain.cpp
index 38888be8a3..da810bc5e6 100644
--- a/src/interfaces/chain.cpp
+++ b/src/interfaces/chain.cpp
@@ -123,7 +123,7 @@ class LockImpl : public Chain::Lock
CBlockIndex* block = LookupBlockIndex(hash);
return block && block->GetAncestor(::chainActive.Height()) == ::chainActive.Tip();
}
- CBlockLocator getLocator() override { return ::chainActive.GetLocator(); }
+ CBlockLocator getTipLocator() override { return ::chainActive.GetLocator(); }
Optional<int> findLocatorFork(const CBlockLocator& locator) override
{
LockAnnotation lock(::cs_main);
diff --git a/src/interfaces/chain.h b/src/interfaces/chain.h
index 735d5b60df..3a54b9164e 100644
--- a/src/interfaces/chain.h
+++ b/src/interfaces/chain.h
@@ -96,7 +96,7 @@ public:
virtual bool isPotentialTip(const uint256& hash) = 0;
//! Get locator for the current chain tip.
- virtual CBlockLocator getLocator() = 0;
+ virtual CBlockLocator getTipLocator() = 0;
//! Return height of the latest block common to locator and chain, which
//! is guaranteed to be an ancestor of the block used to create the
diff --git a/src/interfaces/node.cpp b/src/interfaces/node.cpp
index c574f960e6..a2b89c3f90 100644
--- a/src/interfaces/node.cpp
+++ b/src/interfaces/node.cpp
@@ -67,7 +67,7 @@ public:
void initLogging() override { InitLogging(); }
void initParameterInteraction() override { InitParameterInteraction(); }
std::string getWarnings(const std::string& type) override { return GetWarnings(type); }
- uint32_t getLogCategories() override { return g_logger->GetCategoryMask(); }
+ uint32_t getLogCategories() override { return LogInstance().GetCategoryMask(); }
bool baseInitialize() override
{
return AppInitBasicSetup() && AppInitParameterInteraction() && AppInitSanityChecks() &&
diff --git a/src/interfaces/wallet.cpp b/src/interfaces/wallet.cpp
index 339c5f2487..03b47bd3b5 100644
--- a/src/interfaces/wallet.cpp
+++ b/src/interfaces/wallet.cpp
@@ -212,6 +212,7 @@ public:
}
std::vector<std::string> getDestValues(const std::string& prefix) override
{
+ LOCK(m_wallet.cs_wallet);
return m_wallet.GetDestValues(prefix);
}
void lockCoin(const COutPoint& output) override
@@ -353,7 +354,7 @@ public:
LOCK(m_wallet.cs_wallet);
auto mi = m_wallet.mapWallet.find(txid);
if (mi != m_wallet.mapWallet.end()) {
- num_blocks = locked_chain->getHeight().value_or(-1);
+ num_blocks = locked_chain->getHeight().get_value_or(-1);
in_mempool = mi->second.InMempool();
order_form = mi->second.vOrderForm;
tx_status = MakeWalletTxStatus(*locked_chain, mi->second);
@@ -384,7 +385,7 @@ public:
return false;
}
balances = getBalances();
- num_blocks = locked_chain->getHeight().value_or(-1);
+ num_blocks = locked_chain->getHeight().get_value_or(-1);
return true;
}
CAmount getBalance() override { return m_wallet.GetBalance(); }