aboutsummaryrefslogtreecommitdiff
path: root/src/wallet/init.cpp
diff options
context:
space:
mode:
authorRussell Yanofsky <russ@yanofsky.org>2017-12-05 15:57:12 -0500
committerRussell Yanofsky <russ@yanofsky.org>2021-08-17 03:05:15 -0500
commite4709c7b56612553fb7cbf16ef2d5099c5b732d0 (patch)
tree3184f2fcce535f256d986e94b8d5b359223db150 /src/wallet/init.cpp
parentfdd80b0a53b4af0b29cb6e03118e2456d053a757 (diff)
downloadbitcoin-e4709c7b56612553fb7cbf16ef2d5099c5b732d0.tar.xz
Start using init makeNode, makeChain, etc methods
Use interfaces::Init::make* methods instead of interfaces::Make* functions, so interfaces can be constructed differently in different executables without having to change any code. (So for example bitcoin-gui can make an interfaces::Node pointer that communicates with a bitcoin-node subprocess, while bitcoin-qt can make an interfaces::Node pointer that starts node code in the same process.)
Diffstat (limited to 'src/wallet/init.cpp')
-rw-r--r--src/wallet/init.cpp3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/wallet/init.cpp b/src/wallet/init.cpp
index eb0d6316c0..1d444e5399 100644
--- a/src/wallet/init.cpp
+++ b/src/wallet/init.cpp
@@ -5,6 +5,7 @@
#include <init.h>
#include <interfaces/chain.h>
+#include <interfaces/init.h>
#include <interfaces/wallet.h>
#include <net.h>
#include <node/context.h>
@@ -129,7 +130,7 @@ void WalletInit::Construct(NodeContext& node) const
LogPrintf("Wallet disabled!\n");
return;
}
- auto wallet_client = interfaces::MakeWalletClient(*node.chain, args);
+ auto wallet_client = node.init->makeWalletClient(*node.chain);
node.wallet_client = wallet_client.get();
node.chain_clients.emplace_back(std::move(wallet_client));
}