Skip to content

Commit c1a7b0a

Browse files
committed
f: also account for the lower fees when trimming utxos
1 parent 92d1ce7 commit c1a7b0a

File tree

1 file changed

+1
-1
lines changed
  • lightning/src/events/bump_transaction

1 file changed

+1
-1
lines changed

lightning/src/events/bump_transaction/mod.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -536,7 +536,7 @@ where
536536
}
537537
while !selected_utxos.is_empty()
538538
&& selected_amount - selected_utxos.front().unwrap().0.output.value
539-
>= target_amount_sat + total_fees
539+
>= target_amount_sat + total_fees - selected_utxos.front().unwrap().1
540540
{
541541
let (smallest_value_after_spend_utxo, fee_to_spend_utxo) =
542542
selected_utxos.pop_front().unwrap();

0 commit comments

Comments
 (0)