utils: fix existing node check when keep_old/no_delete is enabled
[project/netifd.git] / main.c
diff --git a/main.c b/main.c
index 7602f23..e008f64 100644 (file)
--- a/main.c
+++ b/main.c
@@ -7,6 +7,7 @@
 #include "netifd.h"
 #include "ubus.h"
 #include "config.h"
+#include "system.h"
 #include "interface.h"
 
 const char *main_path = ".";
@@ -63,6 +64,11 @@ int main(int argc, char **argv)
                return 1;
        }
 
+       if (system_init()) {
+               fprintf(stderr, "Failed to initialize system control\n");
+               return 1;
+       }
+
        config_init_interfaces(NULL);
 
        uloop_run();