Fix config parser.
[apps/pfixtools.git] / postlicyd / main-postlicyd.c
index 7d6970d..3cce400 100644 (file)
@@ -42,6 +42,7 @@
 #include "policy_tokens.h"
 #include "server.h"
 #include "query.h"
+#include "config.h"
 
 #define DAEMON_NAME             "postlicyd"
 #define DEFAULT_PORT            10000
@@ -260,6 +261,11 @@ int main(int argc, char *argv[])
         return EXIT_FAILURE;
     }
 
+    config_t *config = config_read(argv[optind]);
+    if (config == NULL) {
+        return EXIT_FAILURE;
+    }
+
     if (common_setup(pidfile, false, RUNAS_USER, RUNAS_GROUP,
                      daemonize) != EXIT_SUCCESS
         || start_listener(port) < 0) {