Skip to content

Commit

Permalink
lib: remove useless nexthop_group_active_nexthop_num_no_recurse()
Browse files Browse the repository at this point in the history
The nexthop_group_active_nexthop_num_no_recurse() function is no more
used. Let us remove the function call.

Fixes: 148813c ("zebra: zebra_nhg check each nexthop for active, not just number")

Signed-off-by: Philippe Guibert <[email protected]>
  • Loading branch information
pguibert6WIND committed Nov 30, 2023
1 parent 8662509 commit 16a28b7
Show file tree
Hide file tree
Showing 2 changed files with 0 additions and 16 deletions.
14 changes: 0 additions & 14 deletions lib/nexthop_group.c
Original file line number Diff line number Diff line change
Expand Up @@ -105,20 +105,6 @@ uint8_t nexthop_group_active_nexthop_num(const struct nexthop_group *nhg)
return num;
}

uint8_t
nexthop_group_active_nexthop_num_no_recurse(const struct nexthop_group *nhg)
{
struct nexthop *nhop;
uint8_t num = 0;

for (nhop = nhg->nexthop; nhop; nhop = nhop->next) {
if (CHECK_FLAG(nhop->flags, NEXTHOP_FLAG_ACTIVE))
num++;
}

return num;
}

bool nexthop_group_has_label(const struct nexthop_group *nhg)
{
struct nexthop *nhop;
Expand Down
2 changes: 0 additions & 2 deletions lib/nexthop_group.h
Original file line number Diff line number Diff line change
Expand Up @@ -154,8 +154,6 @@ extern uint8_t
nexthop_group_nexthop_num_no_recurse(const struct nexthop_group *nhg);
extern uint8_t
nexthop_group_active_nexthop_num(const struct nexthop_group *nhg);
extern uint8_t
nexthop_group_active_nexthop_num_no_recurse(const struct nexthop_group *nhg);

extern bool nexthop_group_has_label(const struct nexthop_group *nhg);

Expand Down

0 comments on commit 16a28b7

Please sign in to comment.