File tree Expand file tree Collapse file tree 1 file changed +6
-3
lines changed Expand file tree Collapse file tree 1 file changed +6
-3
lines changed Original file line number Diff line number Diff line change @@ -3180,9 +3180,12 @@ impl<Signer: WriteableEcdsaChannelSigner> Channel<Signer> {
3180
3180
let mut reason = OutboundHTLCOutcome :: Success ( None ) ;
3181
3181
mem:: swap ( outcome, & mut reason) ;
3182
3182
if let OutboundHTLCOutcome :: Success ( Some ( preimage) ) = reason {
3183
- // While failing to handle the `Success(None)` case here could result in
3184
- // forgetting some HTLC claims, it is only reachable for HTLCs claimed on LDK
3185
- // 0.0.104 or before, then upgrading LDK before the HTLC is fully resolved.
3183
+ // If a user (a) receives an HTLC claim using LDK 0.0.104 or before, then (b)
3184
+ // upgrades to LDK 0.0.114 or later before the HTLC is fully resolved, we could
3185
+ // have a `Success(None)` reason. In this case we could forget some HTLC
3186
+ // claims, but such an upgrade is unlikely and including claimed HTLCs here
3187
+ // fixes a bug which the user was exposed to on 0.0.104 when they started the
3188
+ // claim anyway.
3186
3189
claimed_htlcs. push ( ( SentHTLCId :: from_source ( & htlc. source ) , preimage) ) ;
3187
3190
}
3188
3191
htlc. state = OutboundHTLCState :: AwaitingRemoteRevokeToRemove ( reason) ;
You can’t perform that action at this time.
0 commit comments