diff options
Diffstat (limited to 'src/fastd.c')
-rw-r--r-- | src/fastd.c | 16 |
1 files changed, 8 insertions, 8 deletions
diff --git a/src/fastd.c b/src/fastd.c index 9115bbf..1f80939 100644 --- a/src/fastd.c +++ b/src/fastd.c @@ -882,6 +882,11 @@ int main(int argc, char *argv[]) { fastd_configure(&ctx, &conf, argc, argv); ctx.conf = &conf; + if (conf.verify_config) { + fastd_config_verify(&ctx, &conf); + exit(0); + } + if (conf.generate_key) { conf.protocol->generate_key(&ctx); exit(0); @@ -896,12 +901,10 @@ int main(int argc, char *argv[]) { init_signals(&ctx); - if (!conf.verify_config) { - if (conf.daemon) - status_fd = daemonize(&ctx); + if (conf.daemon) + status_fd = daemonize(&ctx); - init_log(&ctx); - } + init_log(&ctx); #ifdef HAVE_LIBSODIUM sodium_init(); @@ -915,9 +918,6 @@ int main(int argc, char *argv[]) { fastd_config_check(&ctx, &conf); - if (conf.verify_config) - exit(0); - update_time(&ctx); ctx.next_keepalives = fastd_in_seconds(&ctx, conf.keepalive_interval); |