-
Notifications
You must be signed in to change notification settings - Fork 410
[Custom Transactions] Commitment Transaction & Channel Refactors #3606
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Changes from 1 commit
e58184c
0ac188f
9b71c64
1023d0b
592f17d
728e7c2
22be385
09422dd
935a8fd
ff259ba
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -3703,13 +3703,9 @@ impl<SP: Deref> ChannelContext<SP> where SP::Target: SignerProvider { | |
} else { | ||
log_trace!(logger, " ...not including inbound HTLC {} (hash {}) with value {} due to state ({})", htlc.htlc_id, &htlc.payment_hash, htlc.amount_msat, state_name); | ||
match &htlc.state { | ||
&InboundHTLCState::LocalRemoved(ref reason) => { | ||
if generated_by_local { | ||
if let &InboundHTLCRemovalReason::Fulfill(preimage) = reason { | ||
inbound_htlc_preimages.push(preimage); | ||
value_to_self_msat_offset += htlc.amount_msat as i64; | ||
} | ||
} | ||
&InboundHTLCState::LocalRemoved(InboundHTLCRemovalReason::Fulfill(preimage)) => { | ||
inbound_htlc_preimages.push(preimage); | ||
value_to_self_msat_offset += htlc.amount_msat as i64; | ||
}, | ||
_ => {}, | ||
} | ||
|
@@ -3745,13 +3741,10 @@ impl<SP: Deref> ChannelContext<SP> where SP::Target: SignerProvider { | |
} else { | ||
log_trace!(logger, " ...not including outbound HTLC {} (hash {}) with value {} due to state ({})", htlc.htlc_id, &htlc.payment_hash, htlc.amount_msat, state_name); | ||
match htlc.state { | ||
OutboundHTLCState::AwaitingRemoteRevokeToRemove(OutboundHTLCOutcome::Success(_))|OutboundHTLCState::AwaitingRemovedRemoteRevoke(OutboundHTLCOutcome::Success(_)) => { | ||
value_to_self_msat_offset -= htlc.amount_msat as i64; | ||
}, | ||
OutboundHTLCState::AwaitingRemoteRevokeToRemove(OutboundHTLCOutcome::Success(_)) | | ||
OutboundHTLCState::AwaitingRemovedRemoteRevoke(OutboundHTLCOutcome::Success(_)) | | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more.
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. I don't think I make any changes to that variant ? As before, always subtract from the offset. There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Maybe I'm off on the vocabulary, the tautology to me is the There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Sheesh I was more tired than I thought :( There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. no problem |
||
OutboundHTLCState::RemoteRemoved(OutboundHTLCOutcome::Success(_)) => { | ||
if !generated_by_local { | ||
value_to_self_msat_offset -= htlc.amount_msat as i64; | ||
} | ||
value_to_self_msat_offset -= htlc.amount_msat as i64; | ||
}, | ||
_ => {}, | ||
} | ||
|
Uh oh!
There was an error while loading. Please reload this page.