Skip to content

Commit

Permalink
lightningd: fix crash caused by sending channeld message to closingd
Browse files Browse the repository at this point in the history
```
Sending closingd an invalid message 03f40000006d
...
0x564b55bb7378 fatal
	lightningd/log.c:1035
0x564b55bf7841 subd_send_msg
	lightningd/subd.c:841
0x564b55b87d08 try_update_blockheight
	lightningd/channel_control.c:143
0x564b55b8c497 channel_notify_new_block
	lightningd/channel_control.c:1687
0x564b55bb26bb notify_new_block
	lightningd/lightningd.c:743
```

Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
  • Loading branch information
rustyrussell committed Oct 17, 2023
1 parent 03e51ae commit 91699d8
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion lightningd/channel_control.c
Original file line number Diff line number Diff line change
Expand Up @@ -130,7 +130,7 @@ static void try_update_blockheight(struct lightningd *ld,
}

/* If we're not opened/locked in yet, don't send update */
if (!channel_state_fees_can_change(channel->state))
if (!channel_state_can_add_htlc(channel->state))
return;

/* We don't update the blockheight for non-leased chans */
Expand Down

0 comments on commit 91699d8

Please sign in to comment.