From 5d3e70229e0f12891817b81705652ecf5d49919a Mon Sep 17 00:00:00 2001 From: moneromooo-monero Date: Tue, 24 Apr 2018 01:03:34 +0100 Subject: wallet2: remove old blockchain size cache hack --- src/wallet/wallet2.h | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) (limited to 'src/wallet/wallet2.h') diff --git a/src/wallet/wallet2.h b/src/wallet/wallet2.h index 522a2404a..b3c842288 100644 --- a/src/wallet/wallet2.h +++ b/src/wallet/wallet2.h @@ -745,7 +745,7 @@ namespace tools void get_unconfirmed_payments_out(std::list>& unconfirmed_payments, const boost::optional& subaddr_account = boost::none, const std::set& subaddr_indices = {}) const; void get_unconfirmed_payments(std::list>& unconfirmed_payments, const boost::optional& subaddr_account = boost::none, const std::set& subaddr_indices = {}) const; - uint64_t get_blockchain_current_height() const { return m_local_bc_height; } + uint64_t get_blockchain_current_height() const { return m_light_wallet_blockchain_height ? m_light_wallet_blockchain_height : m_blockchain.size(); } void rescan_spent(); void rescan_blockchain(bool refresh = true); bool is_transfer_unlocked(const transfer_details& td) const; @@ -1200,7 +1200,6 @@ namespace tools std::string m_keys_file; epee::net_utils::http::http_simple_client m_http_client; hashchain m_blockchain; - std::atomic m_local_bc_height; //temporary workaround std::unordered_map m_unconfirmed_txs; std::unordered_map m_confirmed_txs; std::unordered_multimap m_unconfirmed_payments; -- cgit v1.2.3