From eadbdf354a3a3135fd235ce3cce47d8b89f7b279 Mon Sep 17 00:00:00 2001 From: moneromooo-monero Date: Fri, 29 Jan 2016 16:49:53 +0000 Subject: [PATCH] tx_pool: fix use of invalidated iterator --- src/cryptonote_core/tx_pool.cpp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/cryptonote_core/tx_pool.cpp b/src/cryptonote_core/tx_pool.cpp index 2c607fa88..2cef68a85 100644 --- a/src/cryptonote_core/tx_pool.cpp +++ b/src/cryptonote_core/tx_pool.cpp @@ -315,7 +315,8 @@ namespace cryptonote { m_txs_by_fee.erase(sorted_it); } - m_transactions.erase(it++); + auto pit = it++; + m_transactions.erase(pit); }else ++it; }