Time out incoming HTLCs when we reach cltv_expiry (+ test)
[rust-lightning] / lightning / src / util / events.rs
index a0ebc92cc2e385bc2adc633c3224e0af47945d4d..c9492722093161198796373aaa856215476ac0c3 100644 (file)
@@ -55,6 +55,9 @@ pub enum Event {
        /// ChannelManager::fail_htlc_backwards to free up resources for this HTLC.
        /// The amount paid should be considered 'incorrect' when it is less than or more than twice
        /// the amount expected.
+       /// If you fail to call either ChannelManager::claim_funds of
+       /// ChannelManager::fail_htlc_backwards within the HTLC's timeout, the HTLC will be
+       /// automatically failed with PaymentFailReason::PreimageUnknown.
        PaymentReceived {
                /// The hash for which the preimage should be handed to the ChannelManager.
                payment_hash: PaymentHash,