mirror of
https://github.com/bitcoin/bitcoin.git
synced 2026-06-04 02:02:42 +02:00
Merge #10144: Prioritisetransaction wasn't always updating ancestor fee
9bef02eBugfix: ancestor modifed fees were incorrect for descendants (Suhas Daftuar)ba7dd8bTest prioritisetransaction and ancestor fee state (Suhas Daftuar) Tree-SHA512: 01977d88e1afb093a003f22a6f29ea60df3d70a179fe7e55910b9c8c340c4af9fb20cdc804c40235b62c43c453f0194eda0d0d4dbd365d2d98347f5dbe5de01c
This commit is contained in:
@@ -912,6 +912,13 @@ void CTxMemPool::PrioritiseTransaction(const uint256& hash, const CAmount& nFeeD
|
||||
BOOST_FOREACH(txiter ancestorIt, setAncestors) {
|
||||
mapTx.modify(ancestorIt, update_descendant_state(0, nFeeDelta, 0));
|
||||
}
|
||||
// Now update all descendants' modified fees with ancestors
|
||||
setEntries setDescendants;
|
||||
CalculateDescendants(it, setDescendants);
|
||||
setDescendants.erase(it);
|
||||
BOOST_FOREACH(txiter descendantIt, setDescendants) {
|
||||
mapTx.modify(descendantIt, update_ancestor_state(0, nFeeDelta, 0, 0));
|
||||
}
|
||||
}
|
||||
}
|
||||
LogPrintf("PrioritiseTransaction: %s feerate += %s\n", hash.ToString(), FormatMoney(nFeeDelta));
|
||||
|
||||
Reference in New Issue
Block a user