Skip to content

Commit 12dc350

Browse files
committed
f - fix setting need_channel_ready in funding_created/signed
1 parent bf8a8b9 commit 12dc350

File tree

1 file changed

+4
-13
lines changed

1 file changed

+4
-13
lines changed

lightning/src/ln/channel.rs

Lines changed: 4 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -7351,17 +7351,6 @@ impl<SP: Deref> Channel<SP> where
73517351
return None;
73527352
}
73537353

7354-
// If we're still pending the signature on a funding transaction, then we're not ready to send a
7355-
// channel_ready yet.
7356-
if self.context.signer_pending_funding {
7357-
log_debug!(logger, "Can't produce channel_ready: the signer is pending funding.");
7358-
// We make sure to set the channel ready flag here so that we try to
7359-
// generate a channel ready for 0conf channels once our signer unblocked
7360-
// for funding.
7361-
self.context.signer_pending_channel_ready = true;
7362-
return None;
7363-
}
7364-
73657354
self.get_channel_ready(logger)
73667355
}
73677356

@@ -8528,7 +8517,8 @@ impl<SP: Deref> OutboundV1Channel<SP> where SP::Target: SignerProvider {
85288517
holder_commitment_point,
85298518
};
85308519

8531-
let need_channel_ready = channel.check_get_channel_ready(0, logger).is_some();
8520+
let need_channel_ready = channel.check_get_channel_ready(0, logger).is_some()
8521+
|| channel.context.signer_pending_channel_ready;
85328522
channel.monitor_updating_paused(false, false, need_channel_ready, Vec::new(), Vec::new(), Vec::new());
85338523
Ok((channel, channel_monitor))
85348524
}
@@ -8797,7 +8787,8 @@ impl<SP: Deref> InboundV1Channel<SP> where SP::Target: SignerProvider {
87978787
interactive_tx_signing_session: None,
87988788
holder_commitment_point,
87998789
};
8800-
let need_channel_ready = channel.check_get_channel_ready(0, logger).is_some();
8790+
let need_channel_ready = channel.check_get_channel_ready(0, logger).is_some()
8791+
|| channel.context.signer_pending_channel_ready;
88018792
channel.monitor_updating_paused(false, false, need_channel_ready, Vec::new(), Vec::new(), Vec::new());
88028793

88038794
Ok((channel, funding_signed, channel_monitor))

0 commit comments

Comments
 (0)