File tree Expand file tree Collapse file tree 1 file changed +11
-0
lines changed Expand file tree Collapse file tree 1 file changed +11
-0
lines changed Original file line number Diff line number Diff line change @@ -9380,6 +9380,10 @@ where
9380
9380
return Err(ChannelError::close("Peer sent a loose channel_reestablish not after reconnect".to_owned()));
9381
9381
}
9382
9382
9383
+ // A node:
9384
+ // - if `next_commitment_number` is zero:
9385
+ // - MUST immediately fail the channel and broadcast any relevant latest commitment
9386
+ // transaction.
9383
9387
if msg.next_local_commitment_number == 0
9384
9388
|| msg.next_local_commitment_number >= INITIAL_COMMITMENT_NUMBER
9385
9389
|| msg.next_remote_commitment_number >= INITIAL_COMMITMENT_NUMBER
@@ -9610,6 +9614,13 @@ where
9610
9614
let is_awaiting_remote_revoke = self.context.channel_state.is_awaiting_remote_revoke();
9611
9615
let next_counterparty_commitment_number = INITIAL_COMMITMENT_NUMBER - self.context.counterparty_next_commitment_transaction_number + if is_awaiting_remote_revoke { 1 } else { 0 };
9612
9616
9617
+ // A node:
9618
+ // - if `next_commitment_number` is 1 in both the `channel_reestablish` it
9619
+ // sent and received:
9620
+ // - MUST retransmit `channel_ready`.
9621
+ // - otherwise:
9622
+ // - MUST NOT retransmit `channel_ready`, but MAY send `channel_ready` with
9623
+ // a different `short_channel_id` `alias` field.
9613
9624
let channel_ready = if msg.next_local_commitment_number == 1 && INITIAL_COMMITMENT_NUMBER - self.holder_commitment_point.next_transaction_number() == 1 {
9614
9625
// We should never have to worry about MonitorUpdateInProgress resending ChannelReady
9615
9626
self.get_channel_ready(logger)
You can’t perform that action at this time.
0 commit comments