Skip to content

Commit baab0d2

Browse files
committed
[doc]: update reason for deducting change output weight
`CoinGrinder` will also produce change output, listing all the Coin selection algorithms that produces change output is not maintainable, just infer that remaining algorithms all might produce change.
1 parent 7f61d31 commit baab0d2

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/wallet/spend.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -705,7 +705,7 @@ util::Result<SelectionResult> ChooseSelectionResult(interfaces::Chain& chain, co
705705
} else append_error(std::move(bnb_result));
706706
}
707707

708-
// As Knapsack and SRD can create change, also deduce change weight.
708+
// Deduct change weight because remaining Coin Selection algorithms can create change output
709709
max_selection_weight -= (coin_selection_params.change_output_size * WITNESS_SCALE_FACTOR);
710710

711711
// The knapsack solver has some legacy behavior where it will spend dust outputs. We retain this behavior, so don't filter for positive only here.

0 commit comments

Comments
 (0)