Skip to content

Commit

Permalink
lib: Remove route_node_match_ipv[4|6] not being used
Browse files Browse the repository at this point in the history
These functions are not being used.  Let's just remove
them from our code base.

Signed-off-by: Donald Sharp <[email protected]>
  • Loading branch information
donaldsharp committed Sep 26, 2024
1 parent ab24d3e commit 33d1999
Show file tree
Hide file tree
Showing 2 changed files with 0 additions and 30 deletions.
26 changes: 0 additions & 26 deletions lib/table.c
Original file line number Diff line number Diff line change
Expand Up @@ -208,32 +208,6 @@ struct route_node *route_node_match(struct route_table *table,
return NULL;
}

struct route_node *route_node_match_ipv4(struct route_table *table,
const struct in_addr *addr)
{
struct prefix_ipv4 p;

memset(&p, 0, sizeof(p));
p.family = AF_INET;
p.prefixlen = IPV4_MAX_BITLEN;
p.prefix = *addr;

return route_node_match(table, (struct prefix *)&p);
}

struct route_node *route_node_match_ipv6(struct route_table *table,
const struct in6_addr *addr)
{
struct prefix_ipv6 p;

memset(&p, 0, sizeof(p));
p.family = AF_INET6;
p.prefixlen = IPV6_MAX_BITLEN;
p.prefix = *addr;

return route_node_match(table, &p);
}

/* Lookup same prefix node. Return NULL when we can't find route. */
struct route_node *route_node_lookup(struct route_table *table,
union prefixconstptr pu)
Expand Down
4 changes: 0 additions & 4 deletions lib/table.h
Original file line number Diff line number Diff line change
Expand Up @@ -195,10 +195,6 @@ extern struct route_node *route_node_lookup_maynull(struct route_table *table,
union prefixconstptr pu);
extern struct route_node *route_node_match(struct route_table *table,
union prefixconstptr pu);
extern struct route_node *route_node_match_ipv4(struct route_table *table,
const struct in_addr *addr);
extern struct route_node *route_node_match_ipv6(struct route_table *table,
const struct in6_addr *addr);

extern unsigned long route_table_count(struct route_table *table);

Expand Down

0 comments on commit 33d1999

Please sign in to comment.