]> git.puffer.fish Git - mirror/frr.git/commitdiff
zebra: zebra_nhg_rib_find() handle recursive case
authorStephen Worley <sworley@cumulusnetworks.com>
Wed, 17 Jul 2019 17:26:19 +0000 (13:26 -0400)
committerStephen Worley <sworley@cumulusnetworks.com>
Fri, 25 Oct 2019 15:13:41 +0000 (11:13 -0400)
When going through the zebra_nhg_rib_find(), we now handle the
case of if that nexthop has been recursively resolved. A depend
is created and passed along to zebra_nhg_find().

Signed-off-by: Stephen Worley <sworley@cumulusnetworks.com>
zebra/zebra_nhg.c

index 9a4c08be7e058a3adee4d00dbda4b3cac0f56b44..15367b27428a4320210f3870c9a5201910db48d6 100644 (file)
@@ -772,6 +772,10 @@ zebra_nhg_rib_find(uint32_t id, struct nexthop_group *nhg, afi_t rt_afi)
                /* change the afi/vrf_id since its a group */
                nhg_afi = AFI_UNSPEC;
                nhg_vrf_id = 0;
+       } else if (CHECK_FLAG(nhg->nexthop->flags, NEXTHOP_FLAG_RECURSIVE)) {
+               nhg_connected_head_init(&nhg_depends);
+               handle_recursive_depend(&nhg_depends, nhg->nexthop->resolved,
+                                       rt_afi);
        }
 
        if (!zebra_nhg_find(&nhe, id, nhg, &nhg_depends, nhg_vrf_id, nhg_afi,