diff options
author | Dave Barach <dave@barachs.net> | 2019-03-21 18:01:48 -0400 |
---|---|---|
committer | Yichen Wang <yicwang@cisco.com> | 2019-03-25 23:08:09 +0000 |
commit | 327fbae5959f52c7fe670d8d204faaf2c8781a17 (patch) | |
tree | d69b004fece348badcd55e66e132c86c12fefc02 /src/vlib/main.c | |
parent | 0d961549c08ccc6d25cf384fdc8a1c982384219e (diff) |
Ignore SIGTERM during the vpp boot sequence
Call setjmp and mark the setjmp context valid just prior to entering the
vpp main loop.
Change-Id: I26d5cd6a624cb2a497d81eb85a62365621b3b469
Signed-off-by: Dave Barach <dave@barachs.net>
(cherry picked from commit d1e17d00bb81659bf9e45caa62482bf7029d98f7)
Diffstat (limited to 'src/vlib/main.c')
-rw-r--r-- | src/vlib/main.c | 22 |
1 files changed, 11 insertions, 11 deletions
diff --git a/src/vlib/main.c b/src/vlib/main.c index 049d80d9d17..ba0b2ccde98 100644 --- a/src/vlib/main.c +++ b/src/vlib/main.c @@ -2013,6 +2013,17 @@ vlib_main (vlib_main_t * volatile vm, unformat_input_t * input) vec_validate (vm->processing_rpc_requests, 0); _vec_len (vm->processing_rpc_requests) = 0; + if ((error = vlib_call_all_config_functions (vm, input, 0 /* is_early */ ))) + goto done; + + /* Call all main loop enter functions. */ + { + clib_error_t *sub_error; + sub_error = vlib_call_all_main_loop_enter_functions (vm); + if (sub_error) + clib_error_report (sub_error); + } + switch (clib_setjmp (&vm->main_loop_exit, VLIB_MAIN_LOOP_EXIT_NONE)) { case VLIB_MAIN_LOOP_EXIT_NONE: @@ -2027,17 +2038,6 @@ vlib_main (vlib_main_t * volatile vm, unformat_input_t * input) goto done; } - if ((error = vlib_call_all_config_functions (vm, input, 0 /* is_early */ ))) - goto done; - - /* Call all main loop enter functions. */ - { - clib_error_t *sub_error; - sub_error = vlib_call_all_main_loop_enter_functions (vm); - if (sub_error) - clib_error_report (sub_error); - } - vlib_main_loop (vm); done: |