Skip to content

Commit cfff96e

Browse files
committed
f take Val's suggested comment
1 parent 3db4b51 commit cfff96e

File tree

1 file changed

+10
-5
lines changed

1 file changed

+10
-5
lines changed

lightning/src/ln/channel.rs

Lines changed: 10 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -3154,11 +3154,16 @@ impl<ChanSigner: ChannelKeys> Channel<ChanSigner> {
31543154
self.network_sync == UpdateStatus::DisabledMarked
31553155
}
31563156

3157-
/// Called by channelmanager based on chain blocks being connected.
3158-
/// We need to use this to detect funding_signed and outgoing HTLC timed out before we were able
3159-
/// to commit them on remote commitment tx, anything else is handled by the channel_monitor.
3160-
/// In case of Err, the channel may have been closed, at which point the standard requirements
3161-
/// apply - no calls may be made except those explicitly stated to be allowed post-shutdown.
3157+
/// When we receive a new block, we (a) check whether the block contains the funding
3158+
/// transaction (which would start us counting blocks until we send the funding_signed), and
3159+
/// (b) check the height of the block against outbound holding cell HTLCs in case we need to
3160+
/// give up on them prematurely and time them out. Everything else (e.g. commitment
3161+
/// transaction broadcasts, channel closure detection, HTLC transaction broadcasting, etc) is
3162+
/// handled by the CHannelMonitor.
3163+
///
3164+
/// If we return Err, the channel may have been closed, at which point the standard
3165+
/// requirements apply - no calls may be made except those explicitly stated to be allowed
3166+
/// post-shutdown.
31623167
/// Only returns an ErrorAction of DisconnectPeer, if Err.
31633168
///
31643169
/// May return some HTLCs (and their payment_hash) which have timed out and should be failed

0 commit comments

Comments
 (0)