Skip to content

Commit

Permalink
Keep memory pool consistent when stuck tx removed
Browse files Browse the repository at this point in the history
When a stuck tx is removed from memory pool, first remove the associated
spent key images.
  • Loading branch information
warptangent committed Apr 23, 2015
1 parent 07591de commit 9da2039
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions src/cryptonote_core/tx_pool.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -257,6 +257,7 @@ namespace cryptonote
(tx_age > CRYPTONOTE_MEMPOOL_TX_FROM_ALT_BLOCK_LIVETIME && it->second.kept_by_block) )
{
LOG_PRINT_L1("Tx " << it->first << " removed from tx pool due to outdated, age: " << tx_age );
remove_transaction_keyimages(it->second.tx);
m_transactions.erase(it++);
}else
++it;
Expand Down

0 comments on commit 9da2039

Please sign in to comment.