Skip to content

Commit cbc3827

Browse files
committed
f document input size fluctuation
1 parent 41bb5c8 commit cbc3827

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

lightning/src/chain/keysinterface.rs

+3-1
Original file line numberDiff line numberDiff line change
@@ -1017,7 +1017,9 @@ impl KeysManager {
10171017
}
10181018

10191019
debug_assert!(expected_max_weight >= spend_tx.get_weight());
1020-
debug_assert!(expected_max_weight <= spend_tx.get_weight() + descriptors.len() * 4);
1020+
// Note that witnesses with a signature vary somewhat in size, so allow
1021+
// `expected_max_weight` to overshoot by up to 3 bytes per input.
1022+
debug_assert!(expected_max_weight <= spend_tx.get_weight() + descriptors.len() * 3);
10211023

10221024
Ok(spend_tx)
10231025
}

0 commit comments

Comments
 (0)