diff options
| author | Renato Westphal <renato@opensourcerouting.org> | 2016-10-29 22:44:06 -0200 | 
|---|---|---|
| committer | Renato Westphal <renato@opensourcerouting.org> | 2016-11-28 16:18:35 -0200 | 
| commit | 05e8e11e54a38cb9d6ed9c2522b557231197b1bc (patch) | |
| tree | 25a46023e3240694d6467f71335b14703a330fbe /lib/vrf.h | |
| parent | a62c490110765542690860776f44628657a86169 (diff) | |
lib/zebra: put vrf_get() on a diet
Also, for some reason we had two functions to search a VRF by its name:
zebra_vrf_lookup_by_name() and zebra_vrf_list_lookup_by_name().  The first
one would loop through vrf_table and the other one through vrf_list. This
is not necessary anymore, so remove zebra_vrf_lookup_by_name() and rename
zebra_vrf_list_lookup_by_name() to zebra_vrf_lookup_by_name().
Signed-off-by: Renato Westphal <renato@opensourcerouting.org>
Diffstat (limited to 'lib/vrf.h')
| -rw-r--r-- | lib/vrf.h | 3 | 
1 files changed, 1 insertions, 2 deletions
@@ -112,7 +112,6 @@ extern void vrf_add_hook (int, int (*)(vrf_id_t, const char *, void **));  extern struct vrf *vrf_lookup_by_id (vrf_id_t);  extern struct vrf *vrf_lookup_by_name (const char *); -extern struct vrf *vrf_list_lookup_by_name (const char *);  extern struct vrf *vrf_get (vrf_id_t, const char *);  extern void vrf_delete (struct vrf *);  extern int vrf_enable (struct vrf *); @@ -121,7 +120,7 @@ extern vrf_id_t vrf_name_to_id (const char *);  #define VRF_GET_ID(V,NAME)      \    do {                          \        struct vrf *vrf; \ -      if (!(vrf = vrf_list_lookup_by_name(NAME))) \ +      if (!(vrf = vrf_lookup_by_name(NAME))) \          {                                                           \            vty_out (vty, "%% VRF %s not found%s", NAME, VTY_NEWLINE);\            return CMD_WARNING;                                       \  | 
