From f84fc2c9553621648bbaa0c0938cd1b60608e14b Mon Sep 17 00:00:00 2001 From: Donald Sharp Date: Tue, 9 Jan 2018 14:47:11 -0500 Subject: [PATCH] zebra: Move NS/VRF initialization earlier Move the NS/VRF initialization code for zebra to an earlier point in startup. In the future we will have code that will want to install_element into a VRF_NODE from zebra_vty.c Signed-off-by: Donald Sharp --- zebra/main.c | 17 +++++++---------- 1 file changed, 7 insertions(+), 10 deletions(-) diff --git a/zebra/main.c b/zebra/main.c index e26c8e3d69..19b16936d9 100644 --- a/zebra/main.c +++ b/zebra/main.c @@ -300,6 +300,13 @@ int main(int argc, char **argv) zebra_if_init(); zebra_debug_init(); router_id_cmd_init(); + + /* + * Initialize NS( and implicitly the VRF module), and make kernel + * routing socket. */ + zebra_ns_init(); + + zebra_vty_init(); access_list_init(); prefix_list_init(); #if defined(HAVE_RTADV) @@ -317,16 +324,6 @@ int main(int argc, char **argv) /* For debug purpose. */ /* SET_FLAG (zebra_debug_event, ZEBRA_DEBUG_EVENT); */ - /* Initialize NS( and implicitly the VRF module), and make kernel - * routing socket. */ - zebra_ns_init(); - - /* - * Initialize show/config command after the vrf initialization is - * complete - */ - zebra_vty_init(); - #if defined(HANDLE_ZAPI_FUZZING) if (fuzzing) { zserv_read_file(fuzzing); -- 2.39.5