Skip to content

Commit 8d6a021

Browse files
committed
Add signer_pending_open_channel flag
1 parent 24abda1 commit 8d6a021

File tree

1 file changed

+8
-1
lines changed

1 file changed

+8
-1
lines changed

lightning/src/ln/channel.rs

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7275,6 +7275,12 @@ impl<SP: Deref> Channel<SP> where
72757275
pub(super) struct OutboundV1Channel<SP: Deref> where SP::Target: SignerProvider {
72767276
pub context: ChannelContext<SP>,
72777277
pub unfunded_context: UnfundedChannelContext,
7278+
/// We tried to send a `open_channel` message but our commitment point wasn't ready.
7279+
/// This flag tells us we need to send it when we are retried once the
7280+
/// commiment point is ready.
7281+
///
7282+
/// TODO: don't need to persist this since we'll send open_channel again on connect?
7283+
pub signer_pending_open_channel: bool,
72787284
}
72797285

72807286
impl<SP: Deref> OutboundV1Channel<SP> where SP::Target: SignerProvider {
@@ -7319,7 +7325,8 @@ impl<SP: Deref> OutboundV1Channel<SP> where SP::Target: SignerProvider {
73197325
pubkeys,
73207326
logger,
73217327
)?,
7322-
unfunded_context: UnfundedChannelContext { unfunded_channel_age_ticks: 0 }
7328+
unfunded_context: UnfundedChannelContext { unfunded_channel_age_ticks: 0 },
7329+
signer_pending_open_channel: false,
73237330
};
73247331
Ok(chan)
73257332
}

0 commit comments

Comments
 (0)