datapath: Prepare to extend lifetime of kobjects.
[openvswitch] / vswitchd / ovs-brcompatd.c
index 2384f5cabe679ca600aa0d6a5b3308c5cf4f8a4b..9254c5888686fc091273e2c4479e73cc30005dc4 100644 (file)
@@ -931,7 +931,10 @@ main(int argc, char *argv[])
         }
     }
 
-    cfg_read();
+    retval = cfg_read();
+    if (retval) {
+        ovs_fatal(retval, "could not read config file");
+    }
 
     for (;;) {
         unixctl_server_run(unixctl);
@@ -1064,6 +1067,7 @@ parse_options(int argc, char *argv[])
                 "use --help for usage");
     }
 
+    cfg_init();
     config_file = argv[0];
     error = cfg_set_file(config_file);
     if (error) {