Skip to content

Commit 5a6eb89

Browse files
committed
WIP: Address a comment?
1 parent c4f2483 commit 5a6eb89

File tree

1 file changed

+11
-2
lines changed

1 file changed

+11
-2
lines changed

lightning/src/ln/channel.rs

Lines changed: 11 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5607,10 +5607,19 @@ where
56075607
SP::Target: SignerProvider,
56085608
L::Target: Logger,
56095609
{
5610+
let mut commitment_number = self.cur_counterparty_commitment_transaction_number;
5611+
let mut commitment_point = self.counterparty_cur_commitment_point.unwrap();
5612+
5613+
// Use the previous commitment number and point when splicing since they shouldn't change.
5614+
if commitment_number != INITIAL_COMMITMENT_NUMBER {
5615+
commitment_number += 1;
5616+
commitment_point = self.counterparty_prev_commitment_point.unwrap();
5617+
}
5618+
56105619
let commitment_data = self.build_commitment_transaction(
56115620
funding,
5612-
self.cur_counterparty_commitment_transaction_number,
5613-
&self.counterparty_cur_commitment_point.unwrap(),
5621+
commitment_number,
5622+
&commitment_point,
56145623
false,
56155624
false,
56165625
logger,

0 commit comments

Comments
 (0)