]> git.puffer.fish Git - matthieu/frr.git/commitdiff
zebra: Fix multiple levels of static recursion
authorDonald Sharp <sharpd@cumulusnetworks.com>
Sat, 2 Feb 2019 00:08:16 +0000 (19:08 -0500)
committerDonald Sharp <sharpd@cumulusnetworks.com>
Tue, 5 Feb 2019 20:21:26 +0000 (15:21 -0500)
Allow the nexthop-check code to figure out recursive static routes
in a logical manner.

Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
zebra/zebra_rib.c

index 73e4b981b5f7e3278c0eb4ad0fe3952ede52113d..bccf9b6b14ac035c833fb2a3ad361e9d92affe42 100644 (file)
@@ -608,6 +608,9 @@ static int nexthop_active(afi_t afi, struct route_entry *re,
                                if (!CHECK_FLAG(match->status,
                                                ROUTE_ENTRY_INSTALLED))
                                        continue;
+                               if (CHECK_FLAG(newhop->flags,
+                                              NEXTHOP_FLAG_RECURSIVE))
+                                       continue;
 
                                if (set) {
                                        SET_FLAG(nexthop->flags,