summaryrefslogtreecommitdiff
path: root/lib/nexthop.c
diff options
context:
space:
mode:
authorRuss White <russ@riw.us>2024-09-10 10:04:08 -0400
committerGitHub <noreply@github.com>2024-09-10 10:04:08 -0400
commitadd56c61dd510aec79aa62838b090bb43a54c8a9 (patch)
treed1a07e5695c0b2ea8d5442f5b586d51d041ac892 /lib/nexthop.c
parentb774fc683a636e844f7e6456ba3651c3d6173410 (diff)
parentb2c2113f29ddc20affdf349300a5a54e24568634 (diff)
Merge pull request #15259 from dmytroshytyi-6WIND/nexthop_resolution
zebra: add LSP entry to nexthop via recursive (part 2)
Diffstat (limited to 'lib/nexthop.c')
-rw-r--r--lib/nexthop.c9
1 files changed, 9 insertions, 0 deletions
diff --git a/lib/nexthop.c b/lib/nexthop.c
index ac22e7ec84..98b05295b9 100644
--- a/lib/nexthop.c
+++ b/lib/nexthop.c
@@ -713,6 +713,15 @@ struct nexthop *nexthop_next(const struct nexthop *nexthop)
return NULL;
}
+struct nexthop *nexthop_next_resolution(const struct nexthop *nexthop,
+ bool nexthop_resolution)
+{
+ if (nexthop_resolution)
+ return nexthop_next(nexthop);
+ /* no resolution attempt */
+ return nexthop->next;
+}
+
/* Return the next nexthop in the tree that is resolved and active */
struct nexthop *nexthop_next_active_resolved(const struct nexthop *nexthop)
{