chiark / gitweb /
server/*.c: Don't try reading per-user configuration.
[disorder] / server / disorderd.c
index e3e7d8601b23af937edddcb3aff1535fe35ac914..83d0db0ace0d51749a3fe85400f8f2973b048a5e 100644 (file)
@@ -37,7 +37,7 @@ static const struct option options[] = {
 };
 
 /* display usage message and terminate */
-static void help(void) {
+static void attribute((noreturn)) help(void) {
   xprintf("Usage:\n"
          "  disorderd [OPTIONS]\n"
          "Options:\n"
@@ -208,8 +208,7 @@ int main(int argc, char **argv) {
   if(!setlocale(LC_CTYPE, ""))
     disorder_fatal(errno, "error calling setlocale");
   /* garbage-collect PCRE's memory */
-  pcre_malloc = xmalloc;
-  pcre_free = xfree;
+  regexp_setup();
   while((n = getopt_long(argc, argv, "hVc:dfP:NsW", options, 0)) >= 0) {
     switch(n) {
     case 'h': help();
@@ -224,6 +223,7 @@ int main(int argc, char **argv) {
     default: disorder_fatal(0, "invalid option");
     }
   }
+  config_per_user = 0;
   if(wfr) {
     if(config_read(1,  NULL))
       disorder_fatal(0, "cannot read configuration");