diff options
Diffstat (limited to 'src/vnet/adj/adj.h')
-rw-r--r-- | src/vnet/adj/adj.h | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/src/vnet/adj/adj.h b/src/vnet/adj/adj.h index fb3dc368db0..4c38b041b61 100644 --- a/src/vnet/adj/adj.h +++ b/src/vnet/adj/adj.h @@ -432,7 +432,13 @@ extern int adj_per_adj_counters; static inline ip_adjacency_t * adj_get (adj_index_t adj_index) { - return (vec_elt_at_index(adj_pool, adj_index)); + return (pool_elt_at_index(adj_pool, adj_index)); +} + +static inline int +adj_is_valid(adj_index_t adj_index) +{ + return !(pool_is_free_index(adj_pool, adj_index)); } /** |