From c052620e43362c386bffcfa839fc85e8cabbaf68 Mon Sep 17 00:00:00 2001 From: Igor Putovny Date: Mon, 24 Feb 2025 17:18:28 +0100 Subject: [PATCH] Bugfix Assign px_origin of target node in the third pass --- proto/aggregator/trie.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/proto/aggregator/trie.c b/proto/aggregator/trie.c index 879c6cb5b..af4599cc2 100644 --- a/proto/aggregator/trie.c +++ b/proto/aggregator/trie.c @@ -797,6 +797,8 @@ aggregator_third_pass(struct aggregator_proto *p, struct trie_node *node) */ aggregator_find_subtree_prefix(node, &prefix, &pxlen, p->addr_type); + ASSERT_DIE(node->selected_bucket == NULL); + /* Select bucket with the lowest ID */ node->selected_bucket = aggregator_select_lowest_id_bucket(p, node); ASSERT_DIE(node->selected_bucket != NULL); @@ -811,6 +813,7 @@ aggregator_third_pass(struct aggregator_proto *p, struct trie_node *node) /* The closest ancestor of the IN_FIB node with a non-null bucket is the node itself */ node->ancestor = node; node->status = IN_FIB; + node->px_origin = (node->px_origin == ORIGINAL) ? ORIGINAL : AGGREGATED; if (node->child[0]) { -- 2.47.2