File tree Expand file tree Collapse file tree 1 file changed +3
-2
lines changed Expand file tree Collapse file tree 1 file changed +3
-2
lines changed Original file line number Diff line number Diff line change @@ -136,7 +136,7 @@ enum HTLCState {
136136 /// anyway).
137137 LocalRemoved ,
138138 /// Removed by us, sent a new commitment_signed and got a revoke_and_ack. Just waiting on an
139- /// updated local commitment transaction.
139+ /// updated local commitment transaction. Implies local_removed_fulfilled.
140140 LocalRemovedAwaitingCommitment ,
141141}
142142
@@ -663,7 +663,7 @@ impl Channel {
663663 } else {
664664 match htlc. state {
665665 HTLCState :: AwaitingRemoteRevokeToRemove |HTLCState :: AwaitingRemovedRemoteRevoke => {
666- if generated_by_local && htlc. fail_reason . is_none ( ) {
666+ if htlc. fail_reason . is_none ( ) {
667667 value_to_self_msat_offset -= htlc. amount_msat as i64 ;
668668 }
669669 } ,
@@ -678,6 +678,7 @@ impl Channel {
678678 }
679679 } ,
680680 HTLCState :: LocalRemovedAwaitingCommitment => {
681+ assert ! ( htlc. local_removed_fulfilled) ;
681682 value_to_self_msat_offset += htlc. amount_msat as i64 ;
682683 } ,
683684 _ => { } ,
You can’t perform that action at this time.
0 commit comments