diff options
Diffstat (limited to 'include/configreader.h')
-rw-r--r-- | include/configreader.h | 113 |
1 files changed, 48 insertions, 65 deletions
diff --git a/include/configreader.h b/include/configreader.h index 024e28909..b0985f1b5 100644 --- a/include/configreader.h +++ b/include/configreader.h @@ -110,6 +110,49 @@ class ServerLimits } }; +struct CommandLineConf +{ + /** If this value is true, the owner of the + * server specified -nofork on the command + * line, causing the daemon to stay in the + * foreground. + */ + bool nofork; + + /** If this value if true then all log + * messages will be output, regardless of + * the level given in the config file. + * This is set with the -debug commandline + * option. + */ + bool forcedebug; + + /** If this is true then log output will be + * written to the logfile. This is the default. + * If you put -nolog on the commandline then + * the logfile will not be written. + * This is meant to be used in conjunction with + * -debug for debugging without filling up the + * hard disk. + */ + bool writelog; + + /** True if we have been told to run the testsuite from the commandline, + * rather than entering the mainloop. + */ + bool TestSuite; + + /** Saved argc from startup + */ + int argc; + + /** Saved argv from startup + */ + char** argv; + + std::string startup_log; +}; + class CoreExport OperInfo : public refcountbase { public: @@ -186,6 +229,10 @@ class CoreExport ServerConfig */ ServerLimits Limits; + /** Configuration parsed from the command line. + */ + CommandLineConf cmdline; + /** Clones CIDR range for ipv4 (0-32) * Defaults to 32 (checks clones on all IPs seperately) */ @@ -209,11 +256,6 @@ class CoreExport ServerConfig */ int WhoWasMaxKeep; - /** Both for set(g|u)id. - */ - std::string SetUser; - std::string SetGroup; - /** Holds the server name of the local server * as defined by the administrator. */ @@ -316,7 +358,6 @@ class CoreExport ServerConfig /** This variable identifies which usermodes have been diabled. */ - char DisabledUModes[64]; /** This variable identifies which chanmodes have been disabled. @@ -326,43 +367,10 @@ class CoreExport ServerConfig /** The full path to the modules directory. * This is either set at compile time, or * overridden in the configuration file via - * the <options> tag. + * the <path> tag. */ std::string ModPath; - /** The file handle of the logfile. If this - * value is NULL, the log file is not open, - * probably due to a permissions error on - * startup (this should not happen in normal - * operation!). - */ - FILE *log_file; - - /** If this value is true, the owner of the - * server specified -nofork on the command - * line, causing the daemon to stay in the - * foreground. - */ - bool nofork; - - /** If this value if true then all log - * messages will be output, regardless of - * the level given in the config file. - * This is set with the -debug commandline - * option. - */ - bool forcedebug; - - /** If this is true then log output will be - * written to the logfile. This is the default. - * If you put -nolog on the commandline then - * the logfile will not be written. - * This is meant to be used in conjunction with - * -debug for debugging without filling up the - * hard disk. - */ - bool writelog; - /** If set to true, then all opers on this server are * shown with a generic 'is an IRC operator' line rather * than the oper type. Oper types are still used internally. @@ -417,10 +425,6 @@ class CoreExport ServerConfig */ int MaxWhoResults; - /** True if the DEBUG loglevel is selected. - */ - int debugging; - /** How many seconds to wait before exiting * the program when /DIE is correctly issued. */ @@ -484,10 +488,6 @@ class CoreExport ServerConfig */ std::string UserStats; - /** The path and filename of the ircd.log file - */ - std::string logpath; - /** Default channel modes */ std::string DefaultModes; @@ -504,10 +504,6 @@ class CoreExport ServerConfig */ std::map<std::string, int> maxbans; - /** Directory where the inspircd binary resides - */ - std::string MyDir; - /** If set to true, no user DNS lookups are to be performed */ bool NoUserDns; @@ -536,14 +532,6 @@ class CoreExport ServerConfig */ OperIndex oper_blocks; - /** Saved argv from startup - */ - char** argv; - - /** Saved argc from startup - */ - int argc; - /** Max channels per user */ unsigned int MaxChans; @@ -559,11 +547,6 @@ class CoreExport ServerConfig */ std::string sid; - /** True if we have been told to run the testsuite from the commandline, - * rather than entering the mainloop. - */ - bool TestSuite; - /** Construct a new ServerConfig */ ServerConfig(); |