diff options
author | Riccardo Spagni <ric@spagni.net> | 2018-11-16 10:59:25 +0200 |
---|---|---|
committer | Riccardo Spagni <ric@spagni.net> | 2018-11-16 10:59:25 +0200 |
commit | 9827958f5e159c3e44d0dcfc57f32997a75ea020 (patch) | |
tree | f1230666ec64cccabc8e0c48ef47ecbd24122dc4 /src/cryptonote_core/tx_pool.cpp | |
parent | Merge pull request #4765 (diff) | |
parent | tx_pool: allow take_tx to work without m_txs_by_fee_and_receive_time (diff) | |
download | monero-9827958f5e159c3e44d0dcfc57f32997a75ea020.tar.xz |
Merge pull request #4768
cf552c75 tx_pool: allow take_tx to work without m_txs_by_fee_and_receive_time (moneromooo-monero)
Diffstat (limited to 'src/cryptonote_core/tx_pool.cpp')
-rw-r--r-- | src/cryptonote_core/tx_pool.cpp | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/src/cryptonote_core/tx_pool.cpp b/src/cryptonote_core/tx_pool.cpp index 2d340dd41..e2900916b 100644 --- a/src/cryptonote_core/tx_pool.cpp +++ b/src/cryptonote_core/tx_pool.cpp @@ -459,8 +459,6 @@ namespace cryptonote CRITICAL_REGION_LOCAL1(m_blockchain); auto sorted_it = find_tx_in_sorted_container(id); - if (sorted_it == m_txs_by_fee_and_receive_time.end()) - return false; try { @@ -499,7 +497,8 @@ namespace cryptonote return false; } - m_txs_by_fee_and_receive_time.erase(sorted_it); + if (sorted_it != m_txs_by_fee_and_receive_time.end()) + m_txs_by_fee_and_receive_time.erase(sorted_it); ++m_cookie; return true; } |