]> git.netwichtig.de Git - user/henk/code/inspircd.git/blobdiff - include/configreader.h
Space indents must die.
[user/henk/code/inspircd.git] / include / configreader.h
index eefa359c9e523567a90d3643a05afce4350620a4..096d1843afaabaf9e83a071d04d08003518b9607 100644 (file)
 #ifndef INSPIRCD_CONFIGREADER
 #define INSPIRCD_CONFIGREADER
 
+/* handy defines */
+
+/** Determines if a channel op is exempt from given mode m,
+ * in config of server instance s. 
+ */
+#define CHANOPS_EXEMPT(s, m) (s->Config->ExemptChanOps[(unsigned char)m])
+
 #include <sstream>
 #include <string>
 #include <vector>
@@ -173,7 +180,7 @@ typedef std::map<irc::string,char*> operclass_t;
  * and storage of the configuration data needed to run the ircd, such as
  * the servername, connect classes, /ADMIN data, MOTDs and filenames etc.
  */
-class ServerConfig : public Extensible
+class CoreExport ServerConfig : public Extensible
 {
   private:
        /** Creator/owner
@@ -355,6 +362,11 @@ class ServerConfig : public Extensible
         */
        bool HideModeLists[256];
 
+       /** If this is set to true, then channel operators
+        * are exempt from this channel mode. Used for +Sc etc.
+        */
+       bool ExemptChanOps[256];
+
        /** The number of seconds the DNS subsystem
         * will wait before timing out any request.
         */
@@ -426,11 +438,6 @@ class ServerConfig : public Extensible
         */
        char HideKillsServer[MAXBUF];
 
-       /** A list of IP addresses the server is listening
-        * on.
-        */
-       char addrs[MAXBUF][255];
-
        /** The MOTD file, cached in a file_cache type.
         */
        file_cache MOTD;
@@ -453,13 +460,9 @@ class ServerConfig : public Extensible
         */
        std::vector<std::string> module_names;
 
-       /** A list of ports which the server is listening on
-        */
-       int ports[255];
-
-       /** A list of the file descriptors for the listening client ports
+       /** A list of the classes for listening client ports
         */
-       ListenSocket* openSockfd[255];
+       std::vector<ListenSocket*> ports;
 
        /** Boolean sets of which modules implement which functions
         */
@@ -660,7 +663,7 @@ class ServerConfig : public Extensible
        
 };
 
-bool InitializeDisabledCommands(const char* data, InspIRCd* ServerInstance);
+CoreExport bool InitializeDisabledCommands(const char* data, InspIRCd* ServerInstance);
 
 bool InitTypes(ServerConfig* conf, const char* tag);
 bool InitClasses(ServerConfig* conf, const char* tag);