mirror of
https://github.com/aljazceru/lightning.git
synced 2026-01-14 19:44:26 +01:00
lightningd: don't crash when simply using closingd just for retransmission.
test_closing_negotiation_reconnect (__main__.LightningDTests) ... peer state CLOSINGD_COMPLETE should be CLOSINGD_SIGEXCHANGE Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
This commit is contained in:
@@ -1276,6 +1276,10 @@ static int peer_closing_complete(struct peer *peer, const u8 *msg)
|
||||
return -1;
|
||||
}
|
||||
|
||||
/* Retransmission only, ignore closing. */
|
||||
if (peer->state == CLOSINGD_COMPLETE)
|
||||
return -1;
|
||||
|
||||
if (!peer->closing_sig_received) {
|
||||
peer_internal_error(peer,
|
||||
"closing_complete without sending sig!");
|
||||
|
||||
Reference in New Issue
Block a user