Skip to content

Commit fea68f7

Browse files
committed
Fix Channel being left in indeterminite state from 9f9a7a9
9f9a7a9 introduced some changes to channel state transitions but left one case where we'd leave a channel in an undefined phase (upon receiving a `commitment_signed` in the wrong state), which we fix here.
1 parent eaeed77 commit fea68f7

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

lightning/src/ln/channel.rs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1534,6 +1534,7 @@ impl<SP: Deref> Channel<SP> where
15341534
res
15351535
},
15361536
_ => {
1537+
self.phase = phase;
15371538
debug_assert!(!matches!(self.phase, ChannelPhase::Undefined));
15381539
Err(ChannelError::close("Got a commitment_signed message for an unfunded V1 channel!".into()))
15391540
}

0 commit comments

Comments
 (0)