diff options
Diffstat (limited to 'src/interfaces')
-rw-r--r-- | src/interfaces/node.cpp | 2 | ||||
-rw-r--r-- | src/interfaces/wallet.cpp | 8 | ||||
-rw-r--r-- | src/interfaces/wallet.h | 5 |
3 files changed, 11 insertions, 4 deletions
diff --git a/src/interfaces/node.cpp b/src/interfaces/node.cpp index 14af44f924..7f90a38483 100644 --- a/src/interfaces/node.cpp +++ b/src/interfaces/node.cpp @@ -60,7 +60,7 @@ class NodeImpl : public Node void initLogging() override { InitLogging(); } void initParameterInteraction() override { InitParameterInteraction(); } std::string getWarnings(const std::string& type) override { return GetWarnings(type); } - uint32_t getLogCategories() override { return ::logCategories; } + uint32_t getLogCategories() override { return g_logger->GetCategoryMask(); } bool baseInitialize() override { return AppInitBasicSetup() && AppInitParameterInteraction() && AppInitSanityChecks() && diff --git a/src/interfaces/wallet.cpp b/src/interfaces/wallet.cpp index f4dfdae8ae..63b9d80a92 100644 --- a/src/interfaces/wallet.cpp +++ b/src/interfaces/wallet.cpp @@ -152,7 +152,10 @@ public: { return m_wallet.DelAddressBook(dest); } - bool getAddress(const CTxDestination& dest, std::string* name, isminetype* is_mine) override + bool getAddress(const CTxDestination& dest, + std::string* name, + isminetype* is_mine, + std::string* purpose) override { LOCK(m_wallet.cs_wallet); auto it = m_wallet.mapAddressBook.find(dest); @@ -165,6 +168,9 @@ public: if (is_mine) { *is_mine = IsMine(m_wallet, dest); } + if (purpose) { + *purpose = it->second.purpose; + } return true; } std::vector<WalletAddress> getAddresses() override diff --git a/src/interfaces/wallet.h b/src/interfaces/wallet.h index 2a03f6c60a..ff779cd0ad 100644 --- a/src/interfaces/wallet.h +++ b/src/interfaces/wallet.h @@ -99,8 +99,9 @@ public: //! Look up address in wallet, return whether exists. virtual bool getAddress(const CTxDestination& dest, - std::string* name = nullptr, - isminetype* is_mine = nullptr) = 0; + std::string* name, + isminetype* is_mine, + std::string* purpose) = 0; //! Get wallet address list. virtual std::vector<WalletAddress> getAddresses() = 0; |