From 1106a6fde4bfde31a16de45e4cc84ed5da05c5a4 Mon Sep 17 00:00:00 2001 From: Russell Yanofsky Date: Sun, 8 Apr 2018 14:37:50 -0400 Subject: Remove use of uiInterface.LoadWallet in wallet code This also changes the uiInterface.LoadWallet signal argument type from shared_ptr to unique_ptr because CWallet is an internal wallet class that shouldn't be used in non-wallet code (and also can't be passed across process boundaries). This commit does not change behavior. --- src/wallet/wallet.cpp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'src/wallet') diff --git a/src/wallet/wallet.cpp b/src/wallet/wallet.cpp index fb4bd8811f..3d64adec53 100644 --- a/src/wallet/wallet.cpp +++ b/src/wallet/wallet.cpp @@ -12,6 +12,7 @@ #include #include #include +#include #include #include #include @@ -4391,7 +4392,7 @@ std::shared_ptr CWallet::CreateWalletFromFile(interfaces::Chain& chain, } } - uiInterface.LoadWallet(walletInstance); + chain.loadWallet(interfaces::MakeWallet(walletInstance)); // Register with the validation interface. It's ok to do this after rescan since we're still holding cs_main. RegisterValidationInterface(walletInstance.get()); -- cgit v1.2.3