diff options
author | moneromooo-monero <moneromooo-monero@users.noreply.github.com> | 2019-10-15 18:10:29 +0000 |
---|---|---|
committer | moneromooo-monero <moneromooo-monero@users.noreply.github.com> | 2019-11-01 18:59:38 +0000 |
commit | fd35e2304ab5223edd9c6caf03a16c19330e972d (patch) | |
tree | 51d201244d4d772952b0e944425d3ee390ed357c /src/wallet/wallet_rpc_server.cpp | |
parent | wallet2: do not send an unnecessary last getblocks.bin call on refresh (diff) | |
download | monero-fd35e2304ab5223edd9c6caf03a16c19330e972d.tar.xz |
wallet: fix another facet of "did I get some monero" information leak
We get new pool txes before processing any tx, pool or not.
This ensures that if we're asked for a password, this does not
cause a measurable delay in the txpool query after the last
block query.
Diffstat (limited to '')
-rw-r--r-- | src/wallet/wallet_rpc_server.cpp | 10 |
1 files changed, 8 insertions, 2 deletions
diff --git a/src/wallet/wallet_rpc_server.cpp b/src/wallet/wallet_rpc_server.cpp index ec21b2897..de501f056 100644 --- a/src/wallet/wallet_rpc_server.cpp +++ b/src/wallet/wallet_rpc_server.cpp @@ -2438,7 +2438,10 @@ namespace tools if (req.pool) { - m_wallet->update_pool_state(); + std::vector<std::pair<cryptonote::transaction, bool>> process_txs; + m_wallet->update_pool_state(process_txs); + if (!process_txs.empty()) + m_wallet->process_pool_state(process_txs); std::list<std::pair<crypto::hash, tools::wallet2::pool_payment_details>> payments; m_wallet->get_unconfirmed_payments(payments, account_index, subaddr_indices); @@ -2518,7 +2521,10 @@ namespace tools } } - m_wallet->update_pool_state(); + std::vector<std::pair<cryptonote::transaction, bool>> process_txs; + m_wallet->update_pool_state(process_txs); + if (!process_txs.empty()) + m_wallet->process_pool_state(process_txs); std::list<std::pair<crypto::hash, tools::wallet2::pool_payment_details>> pool_payments; m_wallet->get_unconfirmed_payments(pool_payments, req.account_index); |