mirror of
https://github.com/bitcoin/bitcoin.git
synced 2026-05-30 07:43:48 +02:00
Merge bitcoin/bitcoin#28994: wallet: skip BnB when SFFO is enabled
576bee88fdfuzz: disable BnB when SFFO is enabled (furszy)05e5ff194ctest: add coverage for BnB-SFFO restriction (furszy)0c5755761cwallet: create tx, log resulting coin selection info (furszy)5cea25ba79wallet: skip BnB when SFFO is active (Murch) Pull request description: Solves #28918. Coming from https://github.com/bitcoin/bitcoin/issues/28918#issuecomment-1838626406 discussion. The intention is to decouple only the bugfix relevant commits from #28985, allowing them to be included in the 26.x release. This way, we can avoid disabling the coin selection fuzzing test for an entire release. Note: Have introduced few changes to the bug fix commit so that the unit tests pass without the additional burden introduced in #28985. ACKs for top commit: josibake: ACK576bee88fdmurchandamus: ACK576bee88fdachow101: ACK576bee88fdTree-SHA512: f5d90eb3f3f524265afe4719495c9bf30f98b9af26cf039f7df5a7db977abae72caa7a3478cdd0ab10cd143bc1662e8fc5286b5bc10fc10f0dd582a45b45c31a
This commit is contained in:
@@ -116,7 +116,8 @@ FUZZ_TARGET(coinselection)
|
||||
}
|
||||
|
||||
// Run coinselection algorithms
|
||||
auto result_bnb = SelectCoinsBnB(group_pos, target, coin_params.m_cost_of_change, MAX_STANDARD_TX_WEIGHT);
|
||||
auto result_bnb = coin_params.m_subtract_fee_outputs ? util::Error{Untranslated("BnB disabled when SFFO is enabled")} :
|
||||
SelectCoinsBnB(group_pos, target, coin_params.m_cost_of_change, MAX_STANDARD_TX_WEIGHT);
|
||||
if (result_bnb) {
|
||||
assert(result_bnb->GetChange(coin_params.m_cost_of_change, CAmount{0}) == 0);
|
||||
assert(result_bnb->GetSelectedValue() >= target);
|
||||
|
||||
Reference in New Issue
Block a user