diff options
author | Damjan Marion <dmarion@me.com> | 2023-01-26 20:23:11 +0100 |
---|---|---|
committer | Dave Wallace <dwallacelf@gmail.com> | 2023-01-30 17:03:25 +0000 |
commit | a254de408e067df7de94ce9176e104bc2b3a0e67 (patch) | |
tree | 76af439704ff0e59663af8bf9ab8e574e159f801 /src/vlib/unix/main.c | |
parent | a769a508f4f3bb61b372c1382cbcfc531a884d31 (diff) |
vlib: chdir to runtime_dir
Type: improvement
Change-Id: Id8ab75ef4384a1029ab7ee84048f347708307830
Signed-off-by: Damjan Marion <dmarion@me.com>
Diffstat (limited to 'src/vlib/unix/main.c')
-rw-r--r-- | src/vlib/unix/main.c | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/src/vlib/unix/main.c b/src/vlib/unix/main.c index 6b1a32cfee6..3991566ee01 100644 --- a/src/vlib/unix/main.c +++ b/src/vlib/unix/main.c @@ -513,6 +513,9 @@ unix_config (vlib_main_t * vm, unformat_input_t * input) if (error) return error; + if (chdir ((char *) um->runtime_dir) < 0) + return clib_error_return_unix (0, "chdir('%s')", um->runtime_dir); + error = setup_signal_handlers (um); if (error) return error; |