File tree Expand file tree Collapse file tree 2 files changed +24
-2
lines changed Expand file tree Collapse file tree 2 files changed +24
-2
lines changed Original file line number Diff line number Diff line change @@ -8216,6 +8216,20 @@ impl<SP: Deref> InboundV1Channel<SP> where SP::Target: SignerProvider {
8216
8216
8217
8217
Ok((channel, funding_signed, channel_monitor))
8218
8218
}
8219
+
8220
+ /// Indicates that the signer may have some signatures for us, so we should retry if we're
8221
+ /// blocked.
8222
+ #[allow(unused)]
8223
+ pub fn signer_maybe_unblocked<L: Deref>(&mut self, logger: &L) -> Option<msgs::AcceptChannel>
8224
+ where L::Target: Logger
8225
+ {
8226
+ if !self.context.holder_commitment_point.is_available() {
8227
+ self.context.holder_commitment_point.try_resolve_pending(&self.context.holder_signer, &self.context.secp_ctx, logger);
8228
+ }
8229
+ if self.signer_pending_accept_channel && self.context.holder_commitment_point.is_available() {
8230
+ self.generate_accept_channel_message(logger)
8231
+ } else { None }
8232
+ }
8219
8233
}
8220
8234
8221
8235
// A not-yet-funded outbound (from holder) channel using V2 channel establishment.
Original file line number Diff line number Diff line change @@ -8251,9 +8251,17 @@ where
8251
8251
});
8252
8252
}
8253
8253
}
8254
- ChannelPhase::UnfundedInboundV1(_) => {},
8254
+ ChannelPhase::UnfundedInboundV1(chan) => {
8255
+ let logger = WithChannelContext::from(&self.logger, &chan.context, None);
8256
+ if let Some(msg) = chan.signer_maybe_unblocked(&&logger) {
8257
+ pending_msg_events.push(events::MessageSendEvent::SendAcceptChannel {
8258
+ node_id,
8259
+ msg,
8260
+ });
8261
+ }
8262
+ },
8255
8263
}
8256
- };
8264
+ };
8257
8265
8258
8266
let per_peer_state = self.per_peer_state.read().unwrap();
8259
8267
if let Some((counterparty_node_id, channel_id)) = channel_opt {
You can’t perform that action at this time.
0 commit comments