X-Git-Url: http://git.eversberg.eu/gitweb.cgi?p=lcr.git;a=blobdiff_plain;f=options.c;h=9274eb193f5913073f4a3cccb4b60e7978f6e040;hp=88f64246fe932a027736e617ffc787e75168f908;hb=refs%2Fheads%2Fbackup2;hpb=8bb49ccb7b3eba0a3f20d3b097541304b3580f70 diff --git a/options.c b/options.c index 88f6424..9274eb1 100644 --- a/options.c +++ b/options.c @@ -21,7 +21,7 @@ #include struct options options = { - "/usr/local/lcr/log", /* log file */ + LOG_DIR "/log", /* log file */ 0x0000, /* debug mode */ 'a', /* a-law */ "0", /* national prefix */ @@ -31,12 +31,12 @@ struct options options = { "", /* dummy caller id */ 0, /* by default use priority 0 */ "lcr@your.machine", /* source mail adress */ - "/var/tmp", /* path of lock files */ + "/var/run", /* path of lock files */ 0700, /* rights of lcr admin socket */ -1, /* socket user (-1= no change) */ -1, /* socket group (-1= no change) */ - 0, /* enable gsm */ - 1 /* use polling of main loop */ + 0, /* use polling of main loop */ + "/root", /* OTP directory */ }; char options_error[256]; @@ -234,11 +234,15 @@ int read_options(char *options_error) if (!strcmp(option,"socketrights")) { options.socketrights = strtol(param, NULL, 0); } else - if (!strcmp(option,"gsm")) { - options.gsm = 1; - } else if (!strcmp(option,"polling")) { options.polling = 1; + } else + if (!strcmp(option,"otp-dir")) { + if (param[0]==0) { + UPRINT(options_error, "Error in %s (line %d): parameter for option %s missing.\n", filename,line,option); + goto error; + } + SCPY(options.otp_dir, param); } else { UPRINT(options_error, "Error in %s (line %d): wrong option keyword %s.\n", filename,line,option); goto error;