gossipd: don't complain about unknown node_announcements if it's a zombie.

They might not consider it a zombie, and in fact this happens with the
next changes.

Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
This commit is contained in:
Rusty Russell 2023-02-15 15:03:35 +10:30 committed by Alex Myers
parent 167209d595
commit 4fc3c26671
1 changed files with 6 additions and 3 deletions

View File

@ -1816,9 +1816,12 @@ bool routing_add_node_announcement(struct routing_state *rstate,
if (!pna) {
if (was_unknown)
*was_unknown = true;
bad_gossip_order(msg, peer,
type_to_string(tmpctx, struct node_id,
&node_id));
/* Don't complain if it's a zombie node! */
if (!node || !is_node_zombie(node)) {
bad_gossip_order(msg, peer,
type_to_string(tmpctx, struct node_id,
&node_id));
}
return false;
} else if (timestamp <= pna->timestamp)
/* Ignore old ones: they're OK (unless from store). */