From 769ccaa4c37d0ab7caeb12ae0be1640144f52a35 Mon Sep 17 00:00:00 2001 From: Rusty Russell Date: Mon, 10 Feb 2025 16:37:58 +1030 Subject: [PATCH] gossipd: correctly process dying channels. Found by inspection. Minor bug, since we'll catch it on the next block, but annoying. Signed-off-by: Rusty Russell --- gossipd/gossmap_manage.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/gossipd/gossmap_manage.c b/gossipd/gossmap_manage.c index c3779769b..93a7c5bad 100644 --- a/gossipd/gossmap_manage.c +++ b/gossipd/gossmap_manage.c @@ -1278,6 +1278,8 @@ void gossmap_manage_new_block(struct gossmap_manage *gm, u32 new_blockheight) gm->dying_channels[i].gossmap_offset, WIRE_GOSSIP_STORE_CHAN_DYING); tal_arr_remove(&gm->dying_channels, i); + /* Don't skip next one! */ + i--; } }