diff --git a/src/txmempool.cpp b/src/txmempool.cpp index eee6cbf855..01f6c97aea 100644 --- a/src/txmempool.cpp +++ b/src/txmempool.cpp @@ -564,8 +564,12 @@ void CTxMemPool::removeForBlock(const std::vector& vtx, unsigned i } BOOST_FOREACH(const CTransaction& tx, vtx) { - std::list dummy; - remove(tx, dummy, false); + txiter it = mapTx.find(tx.GetHash()); + if (it != mapTx.end()) { + setEntries stage; + stage.insert(it); + RemoveStaged(stage); + } removeConflicts(tx, conflicts); ClearPrioritisation(tx.GetHash()); }