mirror of
https://github.com/bitcoin/bitcoin.git
synced 2025-01-12 04:42:36 -03:00
refactor: remove duplicate code from BlockAssembler
This commit is contained in:
parent
587cbca826
commit
0f40d65321
1 changed files with 2 additions and 6 deletions
|
@ -266,13 +266,9 @@ int BlockAssembler::UpdatePackagesForAdded(const CTxMemPool::setEntries& already
|
||||||
modtxiter mit = mapModifiedTx.find(desc);
|
modtxiter mit = mapModifiedTx.find(desc);
|
||||||
if (mit == mapModifiedTx.end()) {
|
if (mit == mapModifiedTx.end()) {
|
||||||
CTxMemPoolModifiedEntry modEntry(desc);
|
CTxMemPoolModifiedEntry modEntry(desc);
|
||||||
modEntry.nSizeWithAncestors -= it->GetTxSize();
|
mit = mapModifiedTx.insert(modEntry).first;
|
||||||
modEntry.nModFeesWithAncestors -= it->GetModifiedFee();
|
|
||||||
modEntry.nSigOpCostWithAncestors -= it->GetSigOpCost();
|
|
||||||
mapModifiedTx.insert(modEntry);
|
|
||||||
} else {
|
|
||||||
mapModifiedTx.modify(mit, update_for_parent_inclusion(it));
|
|
||||||
}
|
}
|
||||||
|
mapModifiedTx.modify(mit, update_for_parent_inclusion(it));
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
return nDescendantsUpdated;
|
return nDescendantsUpdated;
|
||||||
|
|
Loading…
Reference in a new issue