aboutsummaryrefslogtreecommitdiff
path: root/src/wallet/wallet2.cpp
diff options
context:
space:
mode:
authorRiccardo Spagni <ric@spagni.net>2017-02-05 13:42:41 +0200
committerRiccardo Spagni <ric@spagni.net>2017-02-05 13:42:41 +0200
commit3473af00ad871a52ede2baee14de83eebc7a5760 (patch)
tree277d90aa5ba6b43c42d536b45541ab7a5684a889 /src/wallet/wallet2.cpp
parentMerge pull request #1669 (diff)
parentupdate wallet api tests (diff)
downloadmonero-3473af00ad871a52ede2baee14de83eebc7a5760.tar.xz
Merge pull request #1655
b14d109b update wallet api tests (Jaquee) 0cc50bdd GUI: Improved refresh performance (Jaquee) 805625b5 wallet api: Remove initAsync() and don't start refresh automatically on init (Jaquee) 031b060a wallet2::init() - disconnect before init if connected Makes it possible for GUI to reinit with new daemon without closing and reopening wallet. (Jaquee)
Diffstat (limited to 'src/wallet/wallet2.cpp')
-rw-r--r--src/wallet/wallet2.cpp2
1 files changed, 2 insertions, 0 deletions
diff --git a/src/wallet/wallet2.cpp b/src/wallet/wallet2.cpp
index 9bdfc7b04..c52281a2b 100644
--- a/src/wallet/wallet2.cpp
+++ b/src/wallet/wallet2.cpp
@@ -487,6 +487,8 @@ std::pair<std::unique_ptr<wallet2>, password_container> wallet2::make_new(const
//----------------------------------------------------------------------------------------------------
bool wallet2::init(std::string daemon_address, uint64_t upper_transaction_size_limit)
{
+ if(m_http_client.is_connected())
+ m_http_client.disconnect();
m_upper_transaction_size_limit = upper_transaction_size_limit;
m_daemon_address = std::move(daemon_address);
return m_http_client.set_server(get_daemon_address());