diff options
author | Yves-Alexis Perez <corsac@debian.org> | 2013-02-07 13:27:27 +0100 |
---|---|---|
committer | Yves-Alexis Perez <corsac@debian.org> | 2013-02-07 13:27:27 +0100 |
commit | 7585facf05d927eb6df3929ce09ed5e60d905437 (patch) | |
tree | e4d14b4dc180db20356b6b01ce0112f3a2d7897e /src/starter/starter.c | |
parent | c1343b3278cdf99533b7902744d15969f9d6fdc1 (diff) | |
download | vyos-strongswan-7585facf05d927eb6df3929ce09ed5e60d905437.tar.gz vyos-strongswan-7585facf05d927eb6df3929ce09ed5e60d905437.zip |
Imported Upstream version 5.0.2
Diffstat (limited to 'src/starter/starter.c')
-rw-r--r-- | src/starter/starter.c | 15 |
1 files changed, 12 insertions, 3 deletions
diff --git a/src/starter/starter.c b/src/starter/starter.c index c6efcb2f4..ae6863fd7 100644 --- a/src/starter/starter.c +++ b/src/starter/starter.c @@ -34,7 +34,7 @@ #include <hydra.h> #include <utils/backtrace.h> #include <threading/thread.h> -#include <debug.h> +#include <utils/debug.h> #include "confread.h" #include "files.h" @@ -328,7 +328,8 @@ static bool check_pid(char *pid_file) static void usage(char *name) { fprintf(stderr, "Usage: starter [--nofork] [--auto-update <sec>]\n" - " [--debug|--debug-more|--debug-all|--nolog]\n"); + " [--debug|--debug-more|--debug-all|--nolog]\n" + " [--attach-gdb]\n"); exit(LSB_RC_INVALID_ARGUMENT); } @@ -594,6 +595,10 @@ int main (int argc, char **argv) { if (starter_charon_pid()) { + if (conn->startup == STARTUP_ROUTE) + { + starter_stroke_unroute_conn(conn); + } starter_stroke_del_conn(conn); } conn->state = STATE_TO_ADD; @@ -622,7 +627,7 @@ int main (int argc, char **argv) DBG2(DBG_APP, "Reloading config..."); new_cfg = confread_load(CONFIG_FILE); - if (new_cfg && (new_cfg->err + new_cfg->non_fatal_err == 0)) + if (new_cfg && (new_cfg->err == 0)) { /* Switch to new config. New conn will be loaded below */ @@ -651,6 +656,10 @@ int main (int argc, char **argv) { if (starter_charon_pid()) { + if (conn->startup == STARTUP_ROUTE) + { + starter_stroke_unroute_conn(conn); + } starter_stroke_del_conn(conn); } } |