summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/fastd.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/fastd.c b/src/fastd.c
index 6eea3f0..13c28ba 100644
--- a/src/fastd.c
+++ b/src/fastd.c
@@ -1332,9 +1332,6 @@ int main(int argc, char *argv[]) {
init_tuntap(&ctx);
init_peer_groups(&ctx);
- fastd_config_load_peer_dirs(&ctx, &conf);
- init_peers(&ctx);
-
if (conf.daemon) {
pid_t pid = fork();
if (pid < 0) {
@@ -1362,6 +1359,9 @@ int main(int argc, char *argv[]) {
else if (conf.drop_caps == DROP_CAPS_OFF)
set_user(&ctx);
+ fastd_config_load_peer_dirs(&ctx, &conf);
+ init_peers(&ctx);
+
while (!terminate) {
handle_tasks(&ctx);