]> git.netwichtig.de Git - user/henk/code/inspircd.git/commitdiff
OnRehash changes: split to multiple hooks to clarify use and prevent explosion of...
authordanieldg <danieldg@e03df62e-2008-0410-955e-edbf42e46eb7>
Sun, 24 May 2009 02:53:45 +0000 (02:53 +0000)
committerdanieldg <danieldg@e03df62e-2008-0410-955e-edbf42e46eb7>
Sun, 24 May 2009 02:53:45 +0000 (02:53 +0000)
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@11388 e03df62e-2008-0410-955e-edbf42e46eb7

71 files changed:
include/configreader.h
include/modules.h
src/commands/cmd_rehash.cpp
src/inspircd.cpp
src/modules.cpp
src/modules/extra/m_geoip.cpp
src/modules/extra/m_ldapauth.cpp
src/modules/extra/m_ldapoper.cpp
src/modules/extra/m_mssql.cpp
src/modules/extra/m_mysql.cpp
src/modules/extra/m_pgsql.cpp
src/modules/extra/m_regex_posix.cpp
src/modules/extra/m_sqlauth.cpp
src/modules/extra/m_sqlite3.cpp
src/modules/extra/m_sqllog.cpp
src/modules/extra/m_sqloper.cpp
src/modules/extra/m_ssl_gnutls.cpp
src/modules/extra/m_ssl_openssl.cpp
src/modules/extra/m_ssl_oper_cert.cpp
src/modules/m_alias.cpp
src/modules/m_auditorium.cpp
src/modules/m_banexception.cpp
src/modules/m_banredirect.cpp
src/modules/m_blockamsg.cpp
src/modules/m_blockcaps.cpp
src/modules/m_callerid.cpp
src/modules/m_censor.cpp
src/modules/m_cgiirc.cpp
src/modules/m_chanfilter.cpp
src/modules/m_chanlog.cpp
src/modules/m_chghost.cpp
src/modules/m_cloaking.cpp
src/modules/m_conn_join.cpp
src/modules/m_conn_umodes.cpp
src/modules/m_conn_waitpong.cpp
src/modules/m_connectban.cpp
src/modules/m_connflood.cpp
src/modules/m_dccallow.cpp
src/modules/m_deaf.cpp
src/modules/m_denychans.cpp
src/modules/m_dnsbl.cpp
src/modules/m_filter.cpp
src/modules/m_helpop.cpp
src/modules/m_hidechans.cpp
src/modules/m_hostchange.cpp
src/modules/m_ident.cpp
src/modules/m_invisible.cpp
src/modules/m_inviteexception.cpp
src/modules/m_lockserv.cpp
src/modules/m_maphide.cpp
src/modules/m_nationalchars.cpp
src/modules/m_operjoin.cpp
src/modules/m_operlevels.cpp
src/modules/m_opermodes.cpp
src/modules/m_opermotd.cpp
src/modules/m_override.cpp
src/modules/m_password_hash.cpp
src/modules/m_permchannels.cpp
src/modules/m_remove.cpp
src/modules/m_restrictchans.cpp
src/modules/m_rline.cpp
src/modules/m_safelist.cpp
src/modules/m_securelist.cpp
src/modules/m_sethost.cpp
src/modules/m_shun.cpp
src/modules/m_silence.cpp
src/modules/m_spanningtree/main.cpp
src/modules/m_spanningtree/main.h
src/modules/m_swhois.cpp
src/modules/m_watch.cpp
src/server.cpp

index 29289dcaf505a41d8948b91ea8c664ac3be67ce9..3eb456b1fb46dfd22b3506b3f654e434d734205a 100644 (file)
@@ -343,10 +343,6 @@ class CoreExport ServerConfig : public Extensible
         */
        std::string RehashUserUID;
 
-       /** Rehash parameter, as above
-        */
-       std::string RehashParameter;
-
        /** Error stream, contains error output from any failed configuration parsing.
         */
        std::ostringstream* errstr;
index cc9f10d2c41090aa3aee6db07b7c3b2df6305531..31ed6ec8c5633a495f975175090b8c828e6ba8e9 100644 (file)
@@ -312,11 +312,11 @@ class CoreExport Request : public ModuleMessage
        /** This member holds a pointer to arbitary data set by the emitter of the message
         */
        char* data;
-       /** This should be a null-terminated string identifying the type of request,
-        * all modules should define this and use it to determine the nature of the
-        * request before they attempt to cast the Request in any way.
-        */
-       const char* id;
+       /** This should be a null-terminated string identifying the type of request,
+        * all modules should define this and use it to determine the nature of the
+        * request before they attempt to cast the Request in any way.
+        */
+       const char* id;
        /** This is a pointer to the sender of the message, which can be used to
         * directly trigger events, or to create a reply.
         */
@@ -326,26 +326,26 @@ class CoreExport Request : public ModuleMessage
        Module* dest;
  public:
        /** Create a new Request
-        * This is for the 'old' way of casting whatever the data is
-        * to char* and hoping you get the right thing at the other end.
-        * This is slowly being depreciated in favor of the 'new' way.
+        * This is for the 'old' way of casting whatever the data is
+        * to char* and hoping you get the right thing at the other end.
+        * This is slowly being depreciated in favor of the 'new' way.
         */
        Request(char* anydata, Module* src, Module* dst);
-       /** Create a new Request
-        * This is for the 'new' way of defining a subclass
-        * of Request and defining it in a common header,
+       /** Create a new Request
+        * This is for the 'new' way of defining a subclass
+        * of Request and defining it in a common header,
         * passing an object of your Request subclass through
-        * as a Request* and using the ID string to determine
-        * what to cast it back to and the other end. This is
-        * much safer as there are no casts not confirmed by
-        * the ID string, and all casts are child->parent and
-        * can be checked at runtime with dynamic_cast<>()
-        */
-       Request(Module* src, Module* dst, const char* idstr);
+        * as a Request* and using the ID string to determine
+        * what to cast it back to and the other end. This is
+        * much safer as there are no casts not confirmed by
+        * the ID string, and all casts are child->parent and
+        * can be checked at runtime with dynamic_cast<>()
+        */
+       Request(Module* src, Module* dst, const char* idstr);
        /** Fetch the Request data
         */
        char* GetData();
-       /** Fetch the ID string
+       /** Fetch the ID string
         */
        const char* GetId();
        /** Fetch the request source
@@ -418,14 +418,15 @@ enum Implementation
        I_OnUserInvite, I_OnUserPreMessage, I_OnUserPreNotice, I_OnUserPreNick, I_OnUserMessage, I_OnUserNotice, I_OnMode,
        I_OnGetServerDescription, I_OnSyncUser, I_OnSyncChannel, I_OnSyncChannelMetaData, I_OnSyncUserMetaData,
        I_OnDecodeMetaData, I_ProtoSendMode, I_ProtoSendMetaData, I_OnWallops, I_OnChangeHost, I_OnChangeName, I_OnAddLine,
-       I_OnDelLine, I_OnExpireLine, I_OnCleanup, I_OnUserPostNick, I_OnAccessCheck, I_On005Numeric, I_OnKill, I_OnRemoteKill, I_OnLoadModule, I_OnUnloadModule,
-       I_OnBackgroundTimer, I_OnPreCommand, I_OnCheckReady, I_OnCheckInvite, I_OnRawMode,
+       I_OnDelLine, I_OnExpireLine, I_OnCleanup, I_OnUserPostNick, I_OnAccessCheck, I_On005Numeric, I_OnKill, I_OnRemoteKill,
+       I_OnLoadModule, I_OnUnloadModule, I_OnBackgroundTimer, I_OnPreCommand, I_OnCheckReady, I_OnCheckInvite, I_OnRawMode,
        I_OnCheckKey, I_OnCheckLimit, I_OnCheckBan, I_OnCheckExtBan, I_OnCheckStringExtBan, I_OnStats, I_OnChangeLocalUserHost, I_OnChangeLocalUserGecos,
        I_OnLocalTopicChange, I_OnPostLocalTopicChange, I_OnEvent, I_OnRequest, I_OnGlobalOper, I_OnPostConnect, I_OnAddBan, I_OnDelBan,
        I_OnRawSocketAccept, I_OnRawSocketClose, I_OnRawSocketWrite, I_OnRawSocketRead, I_OnChangeLocalUserGECOS, I_OnUserRegister,
        I_OnChannelPreDelete, I_OnChannelDelete, I_OnPostOper, I_OnSyncOtherMetaData, I_OnSetAway, I_OnUserList,
        I_OnPostCommand, I_OnPostJoin, I_OnWhoisLine, I_OnBuildExemptList, I_OnRawSocketConnect, I_OnGarbageCollect, I_OnBufferFlushed,
        I_OnText, I_OnPassCompare, I_OnRunTestSuite, I_OnNamesListItem, I_OnNumeric, I_OnHookUserIO, I_OnHostCycle,
+       I_OnPreRehash, I_OnModuleRehash,
        I_END
 };
 
@@ -534,14 +535,33 @@ class CoreExport Module : public Extensible
 
        /** Called on rehash.
         * This method is called prior to a /REHASH or when a SIGHUP is received from the operating
-        * system. You should use it to reload any files so that your module keeps in step with the
-        * rest of the application. If a parameter is given, the core has done nothing. The module
-        * receiving the event can decide if this parameter has any relevence to it.
-        * @param user The user performing the rehash, if any -- if this is server initiated, the
-        * value of this variable will be NULL.
-        * @param parameter The (optional) parameter given to REHASH from the user.
+        * system. This is called in all cases -- including when this server will not execute the
+        * rehash because it is directed at a remote server.
+        *
+        * @param user The user performing the rehash, if any. If this is server initiated, the value of
+        * this variable will be NULL.
+        * @param parameter The (optional) parameter given to REHASH from the user. Empty when server
+        * initiated.
+        */
+       virtual void OnPreRehash(User* user, const std::string &parameter);
+
+       /** Called on rehash.
+        * This method is called when a user initiates a module-specific rehash. This can be used to do
+        * expensive operations (such as reloading SSL certificates) that are not executed on a normal
+        * rehash for efficiency. A rehash of this type does not reload the core configuration.
+        *
+        * @param user The user performing the rehash.
+        * @param parameter The parameter given to REHASH
+        */
+       virtual void OnModuleRehash(User* user, const std::string &parameter);
+
+       /** Called on rehash.
+        * This method is called after a rehash has completed. You should use it to reload any module
+        * configuration from the main configuration file.
+        * @param user The user that performed the rehash, if it was initiated by a user and that user
+        * is still connected.
         */
-       virtual void OnRehash(User* user, const std::string &parameter);
+       virtual void OnRehash(User* user);
 
        /** Called whenever a snotice is about to be sent to a snomask.
         * snomask and type may both be modified; the message may not.
@@ -1641,7 +1661,7 @@ class CoreExport ModuleManager : public classbase
         */
        std::string LastModuleError;
 
-       /** The feature names published by various modules
+       /** The feature names published by various modules
         */
        featurelist Features;
 
index b58d6035ac848933ec233d5d4e54f685bd9053cd..9ee71838b3f1444f3793678f4f131b33a8c0d0b0 100644 (file)
@@ -16,7 +16,6 @@
 #include "commands/cmd_rehash.h"
 
 
-
 extern "C" DllExport Command* init_command(InspIRCd* Instance)
 {
        return new CommandRehash(Instance);
@@ -24,36 +23,48 @@ extern "C" DllExport Command* init_command(InspIRCd* Instance)
 
 CmdResult CommandRehash::Handle (const std::vector<std::string>& parameters, User *user)
 {
-       std::string old_disabled = ServerInstance->Config->DisabledCommands;
+       std::string param = parameters.size() ? parameters[0] : "";
+
+       FOREACH_MOD(I_OnPreRehash,OnPreRehash(user, param));
 
-       if (parameters.size() && parameters[0][0] != '-')
+       if (param.empty())
        {
+               // standard rehash of local server
+       }
+       else if (param.find_first_of("*.") != std::string::npos)
+       {
+               // rehash of servers by server name (with wildcard)
                if (!InspIRCd::Match(ServerInstance->Config->ServerName, parameters[0]))
                {
-                       FOREACH_MOD(I_OnRehash,OnRehash(user, parameters[0]));
-                       return CMD_SUCCESS; // rehash for a server, and not for us
+                       // Doesn't match us. PreRehash is already done, nothing left to do
+                       return CMD_SUCCESS;
                }
        }
-       else if (parameters.size())
+       else
        {
-               FOREACH_MOD(I_OnRehash,OnRehash(user, parameters[0]));
-               return CMD_SUCCESS;
-       }
+               // parameterized rehash
 
-       // Rehash for me.
-       FOREACH_MOD(I_OnRehash,OnRehash(user, ""));
-
-       if (IS_LOCAL(user))
-               user->WriteNumeric(RPL_REHASHING, "%s %s :Rehashing",user->nick.c_str(),ServerConfig::CleanFilename(ServerInstance->ConfigFileName));
-       else
-               ServerInstance->PI->SendUserNotice(user, std::string("*** Rehashing server ") + ServerInstance->ConfigFileName);
+               // the leading "-" is optional; remove it if present.
+               if (param[0] == '-')
+                       param = param.substr(1);
 
+               FOREACH_MOD(I_OnModuleRehash,OnModuleRehash(user, param));
+               return CMD_SUCCESS;
+       }
 
+       // Rehash for me. Try to start the rehash thread
        if (!ServerInstance->ConfigThread)
        {
                std::string m = user->nick + " is rehashing config file " + ServerConfig::CleanFilename(ServerInstance->ConfigFileName) + " on " + ServerInstance->Config->ServerName;
                ServerInstance->SNO->WriteGlobalSno('a', m);
 
+               if (IS_LOCAL(user))
+                       user->WriteNumeric(RPL_REHASHING, "%s %s :Rehashing",
+                               user->nick.c_str(),ServerConfig::CleanFilename(ServerInstance->ConfigFileName));
+               else
+                       ServerInstance->PI->SendUserNotice(user, std::string("*** Rehashing server ") +
+                               ServerConfig::CleanFilename(ServerInstance->ConfigFileName));
+
                /* Don't do anything with the logs here -- logs are restarted
                 * after the config thread has completed.
                 */
@@ -63,10 +74,11 @@ CmdResult CommandRehash::Handle (const std::vector<std::string>& parameters, Use
 
 
                ServerInstance->Config->RehashUserUID = user->uuid;
-               ServerInstance->Config->RehashParameter = parameters.size() ? parameters[0] : "";
 
                ServerInstance->ConfigThread = new ConfigReaderThread(ServerInstance, false, ServerInstance->Config->RehashUserUID);
                ServerInstance->Threads->Start(ServerInstance->ConfigThread);
+
+               return CMD_SUCCESS;
        }
        else
        {
@@ -81,7 +93,5 @@ CmdResult CommandRehash::Handle (const std::vector<std::string>& parameters, Use
 
                return CMD_FAILURE;
        }
-
-       return CMD_SUCCESS;
 }
 
index a2a634a64559697358c439a9d97bce73ee431e59..cb019ca7c35f464fcfd5264591337653802b20dc 100644 (file)
@@ -774,11 +774,9 @@ int InspIRCd::Run()
 
                        this->Logs->Log("CONFIG",DEBUG,"Detected ConfigThread exiting, tidying up...");
 
-                       /* These are currently not known to be threadsafe, so they are executed outside
-                        * of the thread. It would be pretty simple to move them to the thread Run method
-                        * once they are known threadsafe with all the correct mutexes in place. This might
-                        * not be worth the effort however as these functions execute relatively quickly
-                        * and would not benefit from being within the config read thread.
+                       /*
+                        * Apply the changed configuration from the rehash. This is not done within the
+                        * configuration thread becasuse they may invoke functions that are not threadsafe.
                         *
                         * XXX: The order of these is IMPORTANT, do not reorder them without testing
                         * thoroughly!!!
@@ -789,13 +787,9 @@ int InspIRCd::Run()
                        this->ResetMaxBans();
                        InitializeDisabledCommands(Config->DisabledCommands, this);
                        User* user = !Config->RehashUserUID.empty() ? FindNick(Config->RehashUserUID) : NULL;
-                       FOREACH_MOD_I(this, I_OnRehash, OnRehash(user, Config->RehashParameter));
+                       FOREACH_MOD_I(this, I_OnRehash, OnRehash(user));
                        this->BuildISupport();
 
-                       /* IMPORTANT: This delete may hang if you fuck up your thread syncronization.
-                        * It will hang waiting for the ConfigThread to 'join' to avoid race conditons,
-                        * until the other thread is completed.
-                        */
                        delete ConfigThread;
                        ConfigThread = NULL;
                }
index 5ffaf120362eeb9e041126a7d67de0e821ed3ce9..5d61812c026976aee26067f16f1d3c5aef29b5f1 100644 (file)
@@ -114,7 +114,9 @@ void                Module::OnUserDisconnect(User*) { }
 void           Module::OnUserJoin(User*, Channel*, bool, bool&) { }
 void           Module::OnPostJoin(User*, Channel*) { }
 void           Module::OnUserPart(User*, Channel*, std::string&, bool&) { }
-void           Module::OnRehash(User*, const std::string&) { }
+void           Module::OnPreRehash(User*, const std::string&) { }
+void           Module::OnModuleRehash(User*, const std::string&) { }
+void           Module::OnRehash(User*) { }
 int            Module::OnUserPreJoin(User*, Channel*, const char*, std::string&, const std::string&) { return 0; }
 void           Module::OnMode(User*, void*, int, const std::deque<std::string>&, const std::deque<TranslateType>&) { }
 Version                Module::GetVersion() { return Version("Misconfigured", VF_VENDOR, -1); }
index d14bacb16f1089bd1958328b22fd7920e5bcca46..21a57a2830e7dfac18aded9ab58749b0b003646c 100644 (file)
@@ -31,7 +31,7 @@ class ModuleGeoIP : public Module
  public:
        ModuleGeoIP(InspIRCd *Me) : Module(Me)
        {
-               OnRehash(NULL, "");
+               OnRehash(NULL);
                Implementation eventlist[] = { I_OnRehash, I_OnUserRegister };
                ServerInstance->Modules->Attach(eventlist, this, 2);
 
@@ -47,7 +47,7 @@ class ModuleGeoIP : public Module
                return Version("$Id$", VF_VENDOR, API_VERSION);
        }
 
-       virtual void OnRehash(User* user, const std::string &parameter)
+       virtual void OnRehash(User* user)
        {
                GeoBans.clear();
 
index c4f04ee4a70c4b050ec60863b1ebe469c99f3b11..b95d32b18ed82effd4f2ec996333b25ddea95c31 100644 (file)
@@ -52,7 +52,7 @@ public:
                conn = NULL;
                Implementation eventlist[] = { I_OnUserDisconnect, I_OnCheckReady, I_OnRehash, I_OnUserRegister };
                ServerInstance->Modules->Attach(eventlist, this, 4);
-               OnRehash(NULL,"");
+               OnRehash(NULL);
        }
 
        virtual ~ModuleLDAPAuth()
@@ -61,7 +61,7 @@ public:
                        ldap_unbind_ext(conn, NULL, NULL);
        }
 
-       virtual void OnRehash(User* user, const std::string &parameter)
+       virtual void OnRehash(User* user)
        {
                ConfigReader Conf(ServerInstance);
 
index 68e7ffc28bfcbbcfda166ed499ceb92ada40f485..43525aa4d5ac2c60232318569998125891de6475 100644 (file)
@@ -47,7 +47,7 @@ public:
                conn = NULL;
                Implementation eventlist[] = { I_OnRehash, I_OnPassCompare };
                ServerInstance->Modules->Attach(eventlist, this, 2);
-               OnRehash(NULL,"");
+               OnRehash(NULL);
        }
 
        virtual ~ModuleLDAPAuth()
@@ -56,7 +56,7 @@ public:
                        ldap_unbind_ext(conn, NULL, NULL);
        }
 
-       virtual void OnRehash(User* user, const std::string &parameter)
+       virtual void OnRehash(User* user)
        {
                ConfigReader Conf(ServerInstance);
 
index 39c6daa811e6d5c49f052b1e6270391ea40cb0f0..5fd62f55ee530a2fa3f5e2cac69a29a1fa17f617 100644 (file)
@@ -789,7 +789,7 @@ class ModuleMsSQL : public Module
                }
        }
 
-       virtual void OnRehash(User* user, const std::string &parameter)
+       virtual void OnRehash(User* user)
        {
                queryDispatcher->LockQueue();
                ReadConf();
index 824a75e46769603914dd590346dfd80ef46e565c..465992d304578da9a7b916ad2e3cdb935970dfd3 100644 (file)
@@ -101,7 +101,7 @@ class ModuleSQL : public Module
         ~ModuleSQL();
         unsigned long NewID();
         const char* OnRequest(Request* request);
-        void OnRehash(User* user, const std::string &parameter);
+        void OnRehash(User* user);
         Version GetVersion();
 };
 
@@ -746,7 +746,7 @@ const char* ModuleSQL::OnRequest(Request* request)
        return NULL;
 }
 
-void ModuleSQL::OnRehash(User* user, const std::string &parameter)
+void ModuleSQL::OnRehash(User* user)
 {
        Dispatcher->LockQueue();
        rehashing = true;
index f353f757585cb33977eca194f8fd8385928c5c61..b417fc0192b039185240dfcb263725789e0ed933 100644 (file)
@@ -796,7 +796,7 @@ class ModulePgSQL : public Module
        }
 
 
-       virtual void OnRehash(User* user, const std::string &parameter)
+       virtual void OnRehash(User* user)
        {
                ReadConf();
        }
index ba653247a48dd262231a727f3b5ed6f8ec1c3b78..6cf7ec44dab0afc53af72934cb264b830157cd33 100644 (file)
@@ -81,7 +81,7 @@ public:
                Me->Modules->PublishInterface("RegularExpression", this);
                Implementation eventlist[] = { I_OnRequest, I_OnRehash };
                Me->Modules->Attach(eventlist, this, 2);
-               OnRehash(NULL, "");
+               OnRehash(NULL);
        }
 
        virtual Version GetVersion()
@@ -94,7 +94,7 @@ public:
                ServerInstance->Modules->UnpublishInterface("RegularExpression", this);
        }
 
-       virtual void OnRehash(User* u, const std::string& parameter)
+       virtual void OnRehash(User* u)
        {
                ConfigReader Conf(ServerInstance);
                extended = Conf.ReadFlag("posix", "extended", 0);
index 8e9d33d5837e68c886927d130797587f153c4b4c..6dc01a5f854932ef6840cfd48e3d78f00c0995e0 100644 (file)
@@ -46,7 +46,7 @@ public:
                if (!SQLprovider)
                        throw ModuleException("Can't find an SQL provider module. Please load one before attempting to load m_sqlauth.");
 
-               OnRehash(NULL,"");
+               OnRehash(NULL);
                Implementation eventlist[] = { I_OnUserDisconnect, I_OnCheckReady, I_OnRequest, I_OnRehash, I_OnUserRegister };
                ServerInstance->Modules->Attach(eventlist, this, 5);
        }
@@ -58,7 +58,7 @@ public:
        }
 
 
-       virtual void OnRehash(User* user, const std::string &parameter)
+       virtual void OnRehash(User* user)
        {
                ConfigReader Conf(ServerInstance);
 
index 354f95a5b4021cdf716aa9c24c29a4199767359c..548af82cc4715f320b0fa16464a73d627ccb2574 100644 (file)
@@ -711,7 +711,7 @@ class ModuleSQLite3 : public Module
                }
        }
 
-       virtual void OnRehash(User* user, const std::string &parameter)
+       virtual void OnRehash(User* user)
        {
                ReadConf();
        }
index ce67651f7ff87da4f086ecad13386c2445bf6acc..c952d495e1d81027efa832b24d4cceb1b1f21f63 100644 (file)
@@ -195,7 +195,7 @@ class ModuleSQLLog : public Module
 
                SQLModule = ServerInstance->Modules->FindFeature("SQL");
 
-               OnRehash(NULL,"");
+               OnRehash(NULL);
                MyMod = this;
                active_queries.clear();
 
@@ -217,7 +217,7 @@ class ModuleSQLLog : public Module
                dbid = Conf.ReadValue("sqllog","dbid",0);       // database id of a database configured in sql module
        }
 
-       virtual void OnRehash(User* user, const std::string &parameter)
+       virtual void OnRehash(User* user)
        {
                ReadConfig();
        }
index 56e0a678fc5efb1522043a3cdf1605013cb5ccc6..e898165a090259b1bd624fa9a5e9c237a9d34a74 100644 (file)
@@ -39,7 +39,7 @@ public:
                ServerInstance->Modules->UseInterface("SQL");
                ServerInstance->Modules->UseInterface("HashRequest");
 
-               OnRehash(NULL, "");
+               OnRehash(NULL);
 
                diduseiface = false;
 
@@ -112,7 +112,7 @@ public:
        }
 
 
-       virtual void OnRehash(User* user, const std::string &parameter)
+       virtual void OnRehash(User* user)
        {
                ConfigReader Conf(ServerInstance);
 
index c284142a5fd8c218afd77f7bda22a5be96480a9c..88c70f5cc281246d4e8a8692a66059f038ab5cd4 100644 (file)
@@ -93,11 +93,6 @@ class CommandStartTLS : public Command
 
 class ModuleSSLGnuTLS : public Module
 {
-
-       ConfigReader* Conf;
-
-       char* dummy;
-
        std::vector<std::string> listenports;
 
        issl_session* sessions;
@@ -130,35 +125,36 @@ class ModuleSSLGnuTLS : public Module
 
                cred_alloc = false;
                // Needs the flag as it ignores a plain /rehash
-               OnRehash(NULL,"ssl");
+               OnModuleRehash(NULL,"ssl");
 
                // Void return, guess we assume success
                gnutls_certificate_set_dh_params(x509_cred, dh_params);
                Implementation eventlist[] = { I_On005Numeric, I_OnRawSocketConnect, I_OnRawSocketAccept, I_OnRawSocketClose, I_OnRawSocketRead, I_OnRawSocketWrite, I_OnCleanup,
-                       I_OnBufferFlushed, I_OnRequest, I_OnSyncUserMetaData, I_OnDecodeMetaData, I_OnUnloadModule, I_OnRehash, I_OnWhois, I_OnPostConnect, I_OnEvent, I_OnHookUserIO };
-               ServerInstance->Modules->Attach(eventlist, this, 17);
+                       I_OnBufferFlushed, I_OnRequest, I_OnSyncUserMetaData, I_OnDecodeMetaData,
+                       I_OnUnloadModule, I_OnRehash, I_OnModuleRehash, I_OnWhois, I_OnPostConnect, I_OnEvent, I_OnHookUserIO };
+               ServerInstance->Modules->Attach(eventlist, this, 18);
 
                starttls = new CommandStartTLS(ServerInstance, this);
                ServerInstance->AddCommand(starttls);
        }
 
-       virtual void OnRehash(User* user, const std::string &param)
+       virtual void OnRehash(User* user)
        {
-               Conf = new ConfigReader(ServerInstance);
+               ConfigReader Conf(ServerInstance);
 
                listenports.clear();
                clientactive = 0;
                sslports.clear();
 
-               for(int index = 0; index < Conf->Enumerate("bind"); index++)
+               for(int index = 0; index < Conf.Enumerate("bind"); index++)
                {
                        // For each <bind> tag
-                       std::string x = Conf->ReadValue("bind", "type", index);
-                       if(((x.empty()) || (x == "clients")) && (Conf->ReadValue("bind", "ssl", index) == "gnutls"))
+                       std::string x = Conf.ReadValue("bind", "type", index);
+                       if(((x.empty()) || (x == "clients")) && (Conf.ReadValue("bind", "ssl", index) == "gnutls"))
                        {
                                // Get the port we're meant to be listening on with SSL
-                               std::string port = Conf->ReadValue("bind", "port", index);
-                               std::string addr = Conf->ReadValue("bind", "address", index);
+                               std::string port = Conf.ReadValue("bind", "port", index);
+                               std::string addr = Conf.ReadValue("bind", "address", index);
 
                                if (!addr.empty())
                                {
@@ -195,22 +191,26 @@ class ModuleSSLGnuTLS : public Module
 
                if (!sslports.empty())
                        sslports.erase(sslports.end() - 1);
+       }
 
+       virtual void OnModuleRehash(User* user, const std::string &param)
+       {
                if(param != "ssl")
-               {
-                       delete Conf;
                        return;
-               }
+
+               OnRehash(user);
+
+               ConfigReader Conf(ServerInstance);
 
                std::string confdir(ServerInstance->ConfigFileName);
                // +1 so we the path ends with a /
                confdir = confdir.substr(0, confdir.find_last_of('/') + 1);
 
-               cafile  = Conf->ReadValue("gnutls", "cafile", 0);
-               crlfile = Conf->ReadValue("gnutls", "crlfile", 0);
-               certfile        = Conf->ReadValue("gnutls", "certfile", 0);
-               keyfile = Conf->ReadValue("gnutls", "keyfile", 0);
-               dh_bits = Conf->ReadInteger("gnutls", "dhbits", 0, false);
+               cafile = Conf.ReadValue("gnutls", "cafile", 0);
+               crlfile = Conf.ReadValue("gnutls", "crlfile", 0);
+               certfile = Conf.ReadValue("gnutls", "certfile", 0);
+               keyfile = Conf.ReadValue("gnutls", "keyfile", 0);
+               dh_bits = Conf.ReadInteger("gnutls", "dhbits", 0, false);
 
                // Set all the default values needed.
                if (cafile.empty())
@@ -272,8 +272,6 @@ class ModuleSSLGnuTLS : public Module
 
                // This may be on a large (once a day or week) timer eventually.
                GenerateDHParams();
-
-               delete Conf;
        }
 
        void GenerateDHParams()
@@ -311,7 +309,7 @@ class ModuleSSLGnuTLS : public Module
                                ServerInstance->Users->QuitUser(user, "SSL module unloading");
                                user->DelIOHook();
                        }
-                       if (user->GetExt("ssl_cert", dummy))
+                       if (user->GetExt("ssl_cert"))
                        {
                                ssl_cert* tofree;
                                user->GetExt("ssl_cert", tofree);
@@ -460,7 +458,7 @@ class ModuleSSLGnuTLS : public Module
 
                EventHandler* user = ServerInstance->SE->GetRef(fd);
 
-               if ((user) && (user->GetExt("ssl_cert", dummy)))
+               if ((user) && (user->GetExt("ssl_cert")))
                {
                        ssl_cert* tofree;
                        user->GetExt("ssl_cert", tofree);
@@ -611,7 +609,7 @@ class ModuleSSLGnuTLS : public Module
                        return;
 
                // Bugfix, only send this numeric for *our* SSL users
-               if (dest->GetExt("ssl", dummy))
+               if (dest->GetExt("ssl"))
                {
                        ServerInstance->SendWhoisLine(source, dest, 320, "%s %s :is using a secure connection", source->nick.c_str(), dest->nick.c_str());
                }
@@ -623,7 +621,7 @@ class ModuleSSLGnuTLS : public Module
                if(extname == "ssl")
                {
                        // check if this user has an swhois field to send
-                       if(user->GetExt(extname, dummy))
+                       if(user->GetExt(extname))
                        {
                                // call this function in the linking module, let it format the data how it
                                // sees fit, and send it on its way. We dont need or want to know how.
@@ -639,7 +637,7 @@ class ModuleSSLGnuTLS : public Module
                {
                        User* dest = (User*)target;
                        // if they dont already have an ssl flag, accept the remote server's
-                       if (!dest->GetExt(extname, dummy))
+                       if (!dest->GetExt(extname))
                        {
                                dest->Extend(extname, "ON");
                        }
@@ -687,7 +685,7 @@ class ModuleSSLGnuTLS : public Module
                        EventHandler *extendme = ServerInstance->SE->GetRef(fd);
                        if (extendme)
                        {
-                               if (!extendme->GetExt("ssl", dummy))
+                               if (!extendme->GetExt("ssl"))
                                        extendme->Extend("ssl", "ON");
                        }
 
index b49d6b0b28343e4620b3965a8e7b607d859bc59d..b1172e179827d2ceba8f7d97230b9b4faef937dc 100644 (file)
@@ -149,10 +149,13 @@ class ModuleSSLOpenSSL : public Module
                SSL_CTX_set_verify(clictx, SSL_VERIFY_PEER | SSL_VERIFY_CLIENT_ONCE, OnVerify);
 
                // Needs the flag as it ignores a plain /rehash
-               OnRehash(NULL,"ssl");
-               Implementation eventlist[] = { I_OnRawSocketConnect, I_OnRawSocketAccept, I_OnRawSocketClose, I_OnRawSocketRead, I_OnRawSocketWrite, I_OnCleanup, I_On005Numeric,
-                       I_OnBufferFlushed, I_OnRequest, I_OnSyncUserMetaData, I_OnDecodeMetaData, I_OnUnloadModule, I_OnRehash, I_OnWhois, I_OnPostConnect, I_OnHookUserIO };
-               ServerInstance->Modules->Attach(eventlist, this, 16);
+               OnModuleRehash(NULL,"ssl");
+               Implementation eventlist[] = { I_OnRawSocketConnect, I_OnRawSocketAccept,
+                       I_OnRawSocketClose, I_OnRawSocketRead, I_OnRawSocketWrite, I_OnCleanup, I_On005Numeric,
+                       I_OnBufferFlushed, I_OnRequest, I_OnSyncUserMetaData, I_OnDecodeMetaData,
+                       I_OnUnloadModule, I_OnRehash, I_OnModuleRehash, I_OnWhois, I_OnPostConnect,
+                       I_OnHookUserIO };
+               ServerInstance->Modules->Attach(eventlist, this, 17);
        }
 
        virtual void OnHookUserIO(User* user, const std::string &targetip)
@@ -164,7 +167,7 @@ class ModuleSSLOpenSSL : public Module
                }
        }
 
-       virtual void OnRehash(User* user, const std::string &param)
+       virtual void OnRehash(User* user)
        {
                ConfigReader Conf(ServerInstance);
 
@@ -217,11 +220,16 @@ class ModuleSSLOpenSSL : public Module
 
                if (!sslports.empty())
                        sslports.erase(sslports.end() - 1);
+       }
 
+       virtual void OnModuleRehash(User* user, const std::string &param)
+       {
                if (param != "ssl")
-               {
                        return;
-               }
+
+               OnRehash(user);
+
+               ConfigReader Conf(ServerInstance);
 
                std::string confdir(ServerInstance->ConfigFileName);
                // +1 so we the path ends with a /
index 08977f15942651ec1c4c31334713d7f9e12ffc5b..d11ec200dc59cbd53b578b721f83f26a64553855 100644 (file)
@@ -87,7 +87,7 @@ class ModuleOperSSLCert : public Module
        }
 
 
-       virtual void OnRehash(User* user, const std::string &parameter)
+       virtual void OnRehash(User* user)
        {
                delete cf;
                cf = new ConfigReader(ServerInstance);
index b27a8f8f03ed271533a801b9b975d455504e5e5f..fb6783d8b0b4ddbd5575da9a3f061838672b50fa 100644 (file)
@@ -378,7 +378,7 @@ class ModuleAlias : public Module
                ServerInstance->Parser->CallHandler(command, pars, user);
        }
 
-       virtual void OnRehash(User* user, const std::string &parameter)
+       virtual void OnRehash(User* user)
        {
                ReadAliases();
        }
index f104c631e3357791cdfe37a483e4a7f1a8296631..3abcdd23765a442f0620289f68420aa41746550c 100644 (file)
@@ -59,7 +59,7 @@ class ModuleAuditorium : public Module
                        throw ModuleException("Could not add new modes!");
                }
 
-               OnRehash(NULL, "");
+               OnRehash(NULL);
 
                Implementation eventlist[] = { I_OnUserJoin, I_OnUserPart, I_OnUserKick, I_OnUserQuit, I_OnNamesListItem, I_OnRehash, I_OnHostCycle };
                Me->Modules->Attach(eventlist, this, 7);
@@ -72,7 +72,7 @@ class ModuleAuditorium : public Module
                delete aum;
        }
 
-       virtual void OnRehash(User* user, const std::string &parameter)
+       virtual void OnRehash(User* user)
        {
                ConfigReader conf(ServerInstance);
                ShowOps = conf.ReadFlag("auditorium", "showops", 0);
index c26e111555f8de83e8181a6428f370bab33c1899..b93e9bf8bef51b3510206865ceae6976f6213c85 100644 (file)
@@ -153,7 +153,7 @@ public:
                be->DoChannelDelete(chan);
        }
 
-       virtual void OnRehash(User* user, const std::string &param)
+       virtual void OnRehash(User* user)
        {
                be->DoRehash();
        }
index 8e9319bcf7f97ec7c8f87ad7b78d46dfba5ea396..f3f68bc7ba79d72b59655d2dad66efe457ed1cf0 100644 (file)
@@ -212,7 +212,7 @@ class ModuleBanRedirect : public Module
                        throw ModuleException("Could not add mode watcher");
                }
 
-               OnRehash(NULL, "");
+               OnRehash(NULL);
 
                Implementation list[] = { I_OnRehash, I_OnUserPreJoin, I_OnChannelDelete, I_OnCleanup };
                Me->Modules->Attach(list, this, 4);
@@ -262,7 +262,7 @@ class ModuleBanRedirect : public Module
                }
        }
 
-       virtual void OnRehash(User* user, const std::string &param)
+       virtual void OnRehash(User* user)
        {
                ExceptionModule = ServerInstance->Modules->Find("m_banexception.so");
        }
index 1707412cf5231155ba8cb4964d11a9ca02578b58..89728bdb9fe3b9fdc1b825bc1a7b57bc4e66a52c 100644 (file)
@@ -46,7 +46,7 @@ class ModuleBlockAmsg : public Module
  public:
        ModuleBlockAmsg(InspIRCd* Me) : Module(Me)
        {
-               this->OnRehash(NULL,"");
+               this->OnRehash(NULL);
                Implementation eventlist[] = { I_OnRehash, I_OnPreCommand, I_OnCleanup };
                ServerInstance->Modules->Attach(eventlist, this, 3);
        }
@@ -61,7 +61,7 @@ class ModuleBlockAmsg : public Module
                return Version("$Id$",VF_VENDOR,API_VERSION);
        }
 
-       virtual void OnRehash(User* user, const std::string &parameter)
+       virtual void OnRehash(User* user)
        {
                ConfigReader Conf(ServerInstance);
 
index 4c1939ca5cc92483ca21eab986705cf11068878b..f5bcfd585bb25b222d66f58467f7da3ee884b144 100644 (file)
@@ -34,7 +34,7 @@ public:
 
        ModuleBlockCAPS(InspIRCd* Me) : Module(Me)
        {
-               OnRehash(NULL,"");
+               OnRehash(NULL);
                bc = new BlockCaps(ServerInstance);
                if (!ServerInstance->Modes->AddMode(bc))
                {
@@ -50,7 +50,7 @@ public:
                ServerInstance->AddExtBanChar('B');
        }
 
-       virtual void OnRehash(User* user, const std::string &param)
+       virtual void OnRehash(User* user)
        {
                ReadConf();
        }
index 75f22940169fef6903dd419d539d4c6683bf56fd..873ec7ed24cbac3abcf4930bf31e76d424e94aef 100644 (file)
@@ -344,7 +344,7 @@ private:
 public:
        ModuleCallerID(InspIRCd* Me) : Module(Me)
        {
-               OnRehash(NULL, "");
+               OnRehash(NULL);
                mycommand = new CommandAccept(ServerInstance, maxaccepts);
                myumode = new User_g(ServerInstance);
 
@@ -477,7 +477,7 @@ public:
                RemoveData(user);
        }
 
-       virtual void OnRehash(User* user, const std::string& parameter)
+       virtual void OnRehash(User* user)
        {
                ConfigReader Conf(ServerInstance);
                maxaccepts = Conf.ReadInteger("callerid", "maxaccepts", "16", 0, true);
index 43fab4006fc95d02d90c1c43d0099c1be1ebe560..0f1c3f61c72a0cfc3dd73053363516867305538f 100644 (file)
@@ -49,7 +49,7 @@ class ModuleCensor : public Module
        {
                /* Read the configuration file on startup.
                 */
-               OnRehash(NULL,"");
+               OnRehash(NULL);
                cu = new CensorUser(ServerInstance);
                cc = new CensorChannel(ServerInstance);
                if (!ServerInstance->Modes->AddMode(cu) || !ServerInstance->Modes->AddMode(cc))
@@ -117,7 +117,7 @@ class ModuleCensor : public Module
                return OnUserPreMessage(user,dest,target_type,text,status,exempt_list);
        }
 
-       virtual void OnRehash(User* user, const std::string &parameter)
+       virtual void OnRehash(User* user)
        {
                /*
                 * reload our config file on rehash - we must destroy and re-allocate the classes
index bb27badd2c0c103f68425888cf68f63f83c52d02..bfd5b5290b79fc3704063e39b90e438a6657981b 100644 (file)
@@ -145,7 +145,7 @@ public:
        ModuleCgiIRC(InspIRCd* Me) : Module(Me)
        {
 
-               OnRehash(NULL,"");
+               OnRehash(NULL);
                mycommand = new CommandWebirc(Me, Hosts, NotifyOpers);
                ServerInstance->AddCommand(mycommand);
 
@@ -159,7 +159,7 @@ public:
                ServerInstance->Modules->SetPriority(this, I_OnUserConnect, PRIORITY_FIRST);
        }
 
-       virtual void OnRehash(User* user, const std::string &parameter)
+       virtual void OnRehash(User* user)
        {
                ConfigReader Conf(ServerInstance);
                Hosts.clear();
index c06fdd36aaa4802ca2f924b49c3df6658cf8e978..02c39aefe007eaca3a8e2741f5cd0be43f6274de 100644 (file)
@@ -74,7 +74,7 @@ class ModuleChanFilter : public Module
                Implementation eventlist[] = { I_OnCleanup, I_OnChannelDelete, I_OnRehash, I_OnUserPreMessage, I_OnUserPreNotice, I_OnSyncChannel };
                ServerInstance->Modules->Attach(eventlist, this, 6);
 
-               OnRehash(NULL, "");
+               OnRehash(NULL);
                ServerInstance->Modules->PublishInterface("ChannelBanList", this);
        }
 
@@ -83,7 +83,7 @@ class ModuleChanFilter : public Module
                cf->DoChannelDelete(chan);
        }
 
-       virtual void OnRehash(User* user, const std::string &parameter)
+       virtual void OnRehash(User* user)
        {
                ConfigReader Conf(ServerInstance);
                hidemask = Conf.ReadFlag("chanfilter", "hidemask", 0);
index 18d13ecdf8bfe222607c0775c3db43c7d36f96d9..259474d74667be7a99ef5c6326c243af44c9ad66 100644 (file)
@@ -29,14 +29,14 @@ class ModuleChanLog : public Module
                Implementation eventlist[] = { I_OnRehash, I_OnSendSnotice };
                ServerInstance->Modules->Attach(eventlist, this, 2);
 
-               OnRehash(NULL, "");
+               OnRehash(NULL);
        }
 
        virtual ~ModuleChanLog()
        {
        }
 
-       virtual void OnRehash(User *user, const std::string &parameter)
+       virtual void OnRehash(User *user)
        {
                ConfigReader MyConf(ServerInstance);
                std::string snomasks;
index 4e2725af4b9a077bfa895b78e497fe8e6bc9040a..e29bb1bed915b853c08f795ef19cbeacceba7b27 100644 (file)
@@ -87,7 +87,7 @@ class ModuleChgHost : public Module
        ModuleChgHost(InspIRCd* Me)
                : Module(Me)
        {
-               OnRehash(NULL,"");
+               OnRehash(NULL);
                mycommand = new CommandChghost(ServerInstance, hostmap);
                ServerInstance->AddCommand(mycommand);
                Implementation eventlist[] = { I_OnRehash };
@@ -95,7 +95,7 @@ class ModuleChgHost : public Module
        }
 
 
-       void OnRehash(User* user, const std::string &parameter)
+       void OnRehash(User* user)
        {
                ConfigReader Conf(ServerInstance);
                std::string hmap = Conf.ReadValue("hostname", "charmap", 0);
index 1b6d2b6bb6b32e58aa8bcce5bdaabad866a06897..59dd008af9609bf0c4f5bcec69f194dab0e654f5 100644 (file)
@@ -267,7 +267,7 @@ class ModuleCloaking : public Module
 
                try
                {
-                       OnRehash(NULL,"");
+                       OnRehash(NULL);
                }
                catch (ModuleException &e)
                {
@@ -369,7 +369,7 @@ class ModuleCloaking : public Module
                return Version("$Id$", VF_COMMON|VF_VENDOR,API_VERSION);
        }
 
-       virtual void OnRehash(User* user, const std::string &parameter)
+       virtual void OnRehash(User* user)
        {
                cu->DoRehash();
        }
index 92cc54f93e7b50c19b7abe6d7ef770c0eb808401..594f1dd061d9b53e9b3e9afa0cd3589465f96cac 100644 (file)
@@ -45,7 +45,7 @@ class ModuleConnJoin : public Module
                ModuleConnJoin(InspIRCd* Me)
                        : Module(Me)
                {
-                       OnRehash(NULL, "");
+                       OnRehash(NULL);
                        Implementation eventlist[] = { I_OnPostConnect, I_OnRehash };
                        ServerInstance->Modules->Attach(eventlist, this, 2);
                }
@@ -56,7 +56,7 @@ class ModuleConnJoin : public Module
                }
 
 
-               virtual void OnRehash(User* user, const std::string &parameter)
+               virtual void OnRehash(User* user)
                {
                        ConfigReader* conf = new ConfigReader(ServerInstance);
                        JoinChan = conf->ReadValue("autojoin", "channel", 0);
index 34ca86db2bfd4a477ae8c469c47979e583bd32ad..f502ea57c6cb2c62bf26d38b5b956d8ef174bc2b 100644 (file)
@@ -33,7 +33,7 @@ class ModuleModesOnConnect : public Module
        }
 
 
-       virtual void OnRehash(User* user, const std::string &parameter)
+       virtual void OnRehash(User* user)
        {
                delete Conf;
                Conf = new ConfigReader(ServerInstance);
index 934b5ffd8b7c2e606e42a12035006e58248909c5..9a0adc3d6646507b9fa99d6da968f1727d6fb856 100644 (file)
@@ -25,12 +25,12 @@ class ModuleWaitPong : public Module
        ModuleWaitPong(InspIRCd* Me)
         : Module(Me), extenstr("waitpong_pingstr")
        {
-               OnRehash(NULL,"");
+               OnRehash(NULL);
                Implementation eventlist[] = { I_OnUserRegister, I_OnCheckReady, I_OnPreCommand, I_OnRehash, I_OnUserDisconnect, I_OnCleanup };
                ServerInstance->Modules->Attach(eventlist, this, 6);
        }
 
-       virtual void OnRehash(User* user, const std::string &param)
+       virtual void OnRehash(User* user)
        {
                ConfigReader Conf(ServerInstance);
 
index 8a5a1cb926f2d1ad9d6c31ff7f570ec1c07ac0ee..19408046fcc4356889d07d8e31d5090140bfae68 100644 (file)
@@ -29,7 +29,7 @@ class ModuleConnectBan : public Module
        {
                Implementation eventlist[] = { I_OnUserConnect, I_OnGarbageCollect, I_OnRehash };
                ServerInstance->Modules->Attach(eventlist, this, 3);
-               OnRehash(NULL, "");
+               OnRehash(NULL);
        }
 
        virtual ~ModuleConnectBan()
@@ -41,7 +41,7 @@ class ModuleConnectBan : public Module
                return Version("$Id$", VF_VENDOR,API_VERSION);
        }
 
-       virtual void OnRehash(User* user, const std::string &parameter)
+       virtual void OnRehash(User* user)
        {
                ConfigReader Conf(ServerInstance);
                std::string duration;
index cb5c8575561aacbda935ece783e9fbe5d049b273..6828d28f2e58b143e65b172758d497244e43f569 100644 (file)
@@ -106,7 +106,7 @@ public:
                return 0;
        }
 
-       virtual void OnRehash(User* user, const std::string &parameter)
+       virtual void OnRehash(User* user)
        {
                InitConf();
        }
index dc7df8dded0bd06cc2fe8312caca227464eac36e..56345932c56c0d3e92bd43b91a4cb3b0ad2a3815 100644 (file)
@@ -259,7 +259,7 @@ class ModuleDCCAllow : public Module
        }
 
 
-       virtual void OnRehash(User* user, const std::string &parameter)
+       virtual void OnRehash(User* user)
        {
                delete Conf;
                Conf = new ConfigReader(ServerInstance);
index a291189fa537ff844b7c92da4f08c7e9bc590e49..c72d26fe5500392f6cfbae26163e7ef7e7fc573b 100644 (file)
@@ -60,13 +60,13 @@ class ModuleDeaf : public Module
                if (!ServerInstance->Modes->AddMode(m1))
                        throw ModuleException("Could not add new modes!");
 
-               OnRehash(NULL, "");
+               OnRehash(NULL);
                Implementation eventlist[] = { I_OnUserPreMessage, I_OnUserPreNotice, I_OnRehash, I_OnBuildExemptList };
                ServerInstance->Modules->Attach(eventlist, this, 4);
        }
 
 
-       virtual void OnRehash(User* user, const std::string&)
+       virtual void OnRehash(User* user)
        {
                ConfigReader* conf = new ConfigReader(ServerInstance);
                deaf_bypasschars = conf->ReadValue("deaf", "bypasschars", 0);
index dbfe74400d1d5e7084b902dc2000f5f6e520c4ca..3a9df37a252e66d3b0fdccf67e8e3c84e7d4dbca 100644 (file)
@@ -31,7 +31,7 @@ class ModuleDenyChannels : public Module
                ServerInstance->Modules->Attach(eventlist, this, 2);
        }
 
-       virtual void OnRehash(User* user, const std::string &param)
+       virtual void OnRehash(User* user)
        {
                delete Conf;
                Conf = new ConfigReader(ServerInstance);
index 134406e02317d4c810ae6005004a087ab497a7e8..2ee71ce87300fecffa556bf115c9b64dbc2bd465 100644 (file)
@@ -304,7 +304,7 @@ class ModuleDNSBL : public Module
                delete MyConf;
        }
 
-       virtual void OnRehash(User* user, const std::string &parameter)
+       virtual void OnRehash(User* user)
        {
                ReadConf();
        }
index b7d97777117e3642ba659d95865a36e81c9250e1..1818ca17d69a8509151aef4effaaf3e6d7f4a1ac 100644 (file)
@@ -113,7 +113,7 @@ protected:
        virtual void SendFilter(Module* proto, void* opaque, FilterResult* iter);
        virtual std::pair<bool, std::string> AddFilter(const std::string &freeform, const std::string &type, const std::string &reason, long duration, const std::string &flags) = 0;
        virtual int OnUserPreNotice(User* user,void* dest,int target_type, std::string &text, char status, CUList &exempt_list);
-       virtual void OnRehash(User* user, const std::string &parameter);
+       virtual void OnRehash(User* user);
        virtual Version GetVersion();
        std::string EncodeFilter(FilterResult* filter);
        FilterResult DecodeFilter(const std::string &data);
@@ -409,7 +409,7 @@ int FilterBase::OnPreCommand(std::string &command, std::vector<std::string> &par
        return 0;
 }
 
-void FilterBase::OnRehash(User* user, const std::string &parameter)
+void FilterBase::OnRehash(User* user)
 {
        ConfigReader MyConf(ServerInstance);
        std::vector<std::string>().swap(exemptfromfilter);
@@ -559,7 +559,7 @@ class ModuleFilter : public FilterBase
        ModuleFilter(InspIRCd* Me)
        : FilterBase(Me, "m_filter.so")
        {
-               OnRehash(NULL,"");
+               OnRehash(NULL);
        }
 
        virtual ~ModuleFilter()
@@ -636,10 +636,10 @@ class ModuleFilter : public FilterBase
                return std::make_pair(true, "");
        }
 
-       virtual void OnRehash(User* user, const std::string &parameter)
+       virtual void OnRehash(User* user)
        {
                ConfigReader MyConf(ServerInstance);
-               FilterBase::OnRehash(user, parameter);
+               FilterBase::OnRehash(user);
                ReadFilters(MyConf);
        }
 
index 5a0a675074f7e32bbe9da3e63c66d85a635e1e51..0f65d7dfa0e983c75f0c3e783354717ce7cafdf6 100644 (file)
@@ -164,7 +164,7 @@ class ModuleHelpop : public Module
                }
 
 
-               virtual void OnRehash(User* user, const std::string &parameter)
+               virtual void OnRehash(User* user)
                {
                        ReadConfig();
                }
index 5ed2552b95a7b7f78720516309a399eb29437de9..8ca14f1a4123d2cd21d3e6ad5106757868d32de0 100644 (file)
@@ -58,7 +58,7 @@ class ModuleHideChans : public Module
                        throw ModuleException("Could not add new modes!");
                Implementation eventlist[] = { I_OnWhoisLine, I_OnRehash };
                ServerInstance->Modules->Attach(eventlist, this, 2);
-               OnRehash(NULL, "");
+               OnRehash(NULL);
        }
 
        virtual ~ModuleHideChans()
@@ -72,7 +72,7 @@ class ModuleHideChans : public Module
                return Version("$Id$", VF_COMMON | VF_VENDOR, API_VERSION);
        }
 
-       virtual void OnRehash(User* user, const std::string &parameter)
+       virtual void OnRehash(User* user)
        {
                ConfigReader conf(ServerInstance);
                AffectsOpers = conf.ReadFlag("hidechans", "affectsopers", 0);
index 10493f9d0a9b3c7d6c05e0f9299e104396b68ffc..b681a4648038c26aaf005e6471cad4c4b2ab45c6 100644 (file)
@@ -39,7 +39,7 @@ class ModuleHostChange : public Module
        ModuleHostChange(InspIRCd* Me)
                : Module(Me)
        {
-               OnRehash(NULL,"");
+               OnRehash(NULL);
                Implementation eventlist[] = { I_OnRehash, I_OnUserConnect };
                ServerInstance->Modules->Attach(eventlist, this, 2);
        }
@@ -60,7 +60,7 @@ class ModuleHostChange : public Module
        }
 
 
-       virtual void OnRehash(User* user, const std::string &parameter)
+       virtual void OnRehash(User* user)
        {
                ConfigReader Conf(ServerInstance);
                MySuffix = Conf.ReadValue("host","suffix",0);
index 6db5847537af9b64e6830c54637189b8b799765c..24e27d560455e926e8af93a06e7b9712761885cb 100644 (file)
@@ -323,7 +323,7 @@ class ModuleIdent : public Module
        ModuleIdent(InspIRCd *Me) : Module(Me)
        {
                Conf = new ConfigReader(ServerInstance);
-               OnRehash(NULL, "");
+               OnRehash(NULL);
                Implementation eventlist[] = { I_OnRehash, I_OnUserRegister, I_OnCheckReady, I_OnCleanup, I_OnUserDisconnect };
                ServerInstance->Modules->Attach(eventlist, this, 5);
        }
@@ -338,7 +338,7 @@ class ModuleIdent : public Module
                return Version("$Id$", VF_VENDOR, API_VERSION);
        }
 
-       virtual void OnRehash(User *user, const std::string &param)
+       virtual void OnRehash(User *user)
        {
                delete Conf;
                Conf = new ConfigReader(ServerInstance);
index 1236859da14d84d5d7d20247051e03c511c5e03d..2e34b4f5d13b22dd83d25b7b74b86bda3084035d 100644 (file)
@@ -161,7 +161,7 @@ class ModuleInvisible : public Module
 
        virtual Version GetVersion();
        virtual void OnUserJoin(User* user, Channel* channel, bool sync, bool &silent);
-       virtual void OnRehash(User* user, const std::string &parameter);
+       virtual void OnRehash(User* user);
        void OnUserPart(User* user, Channel* channel, std::string &partmessage, bool &silent);
        void OnUserQuit(User* user, const std::string &reason, const std::string &oper_message);
        bool OnHostCycle(User* user);
@@ -188,7 +188,7 @@ void ModuleInvisible::OnUserJoin(User* user, Channel* channel, bool sync, bool &
        }
 }
 
-void ModuleInvisible::OnRehash(User* user, const std::string &parameter)
+void ModuleInvisible::OnRehash(User* user)
 {
        delete conf;
        conf = new ConfigReader(ServerInstance);
index e3c243f84237ab83730d033d511c2d5330ec9b8e..130ca9a430990c05b3ab63c0f8a4b8ac86ab5581 100644 (file)
@@ -102,7 +102,7 @@ public:
                ie->DoChannelDelete(chan);
        }
 
-       virtual void OnRehash(User* user, const std::string &param)
+       virtual void OnRehash(User* user)
        {
                ie->DoRehash();
        }
index 946abc96871599d85947aa6ccba10bc5e2000860..f25ba0553346baa4180eb912e8506880c206bcee 100644 (file)
@@ -97,7 +97,7 @@ public:
        }
 
 
-       virtual void OnRehash(User* user, const std::string &parameter)
+       virtual void OnRehash(User* user)
        {
                ResetLocked();
        }
index 7f96f18dd30619324a8d133bd1bd89e4ff5e16ae..637efa7653c52721fc6f9636dfa2375e9cbbd9aa 100644 (file)
@@ -25,10 +25,10 @@ class ModuleMapHide : public Module
                // Create a new command
                ServerInstance->Modules->Attach(I_OnPreCommand, this);
                ServerInstance->Modules->Attach(I_OnRehash, this);
-               OnRehash(NULL, "");
+               OnRehash(NULL);
        }
 
-       void OnRehash(User* user, const std::string &parameter)
+       void OnRehash(User* user)
        {
                ConfigReader MyConf(ServerInstance);
                url = MyConf.ReadValue("security", "maphide", 0);
index 72f2337152a3a019dfb0202719ae63479cd21640..f27b54a520c82d5d4f3a2cb99676fd0bbce4985a 100755 (executable)
@@ -240,7 +240,7 @@ class ModuleNationalChars : public Module
 
                Implementation eventlist[] = { I_OnRehash, I_On005Numeric };
                ServerInstance->Modules->Attach(eventlist, this, 2);
-               OnRehash(NULL, "");
+               OnRehash(NULL);
        }
 
        virtual void On005Numeric(std::string &output)
@@ -250,7 +250,7 @@ class ModuleNationalChars : public Module
                SearchAndReplace(output, std::string("CASEMAPPING=rfc1459"), tmp);
        }
 
-       virtual void OnRehash(User* user, const std::string &parameter)
+       virtual void OnRehash(User* user)
        {
                ConfigReader* conf = new ConfigReader(ServerInstance);
                charset = conf->ReadValue("nationalchars", "file", 0);
index 22482faace9bed22f18925c1f6695de6cce1bdb0..7b02958461ff5b4031ca8f91055d598b6ddc1ef4 100644 (file)
@@ -45,13 +45,13 @@ class ModuleOperjoin : public Module
        public:
                ModuleOperjoin(InspIRCd* Me) : Module(Me)
                {
-                       OnRehash(NULL, "");
+                       OnRehash(NULL);
                Implementation eventlist[] = { I_OnPostOper, I_OnRehash };
                ServerInstance->Modules->Attach(eventlist, this, 2);
                }
 
 
-               virtual void OnRehash(User* user, const std::string &parameter)
+               virtual void OnRehash(User* user)
                {
                        ConfigReader* conf = new ConfigReader(ServerInstance);
 
index 6aacc049686e5cab30dd2386204639c4c2ec2212..74a6e2c5fd87c4c5569ac47ae38d196787294b05 100644 (file)
@@ -33,7 +33,7 @@ class ModuleOperLevels : public Module
                }
 
 
-               virtual void OnRehash(User* user, const std::string &parameter)
+               virtual void OnRehash(User* user)
                {
                        delete conf;
                        conf = new ConfigReader(ServerInstance);
index 33c8c54b04b910bee659c61dac29a6c8b765601b..1efefe75344d01ac675e63162380d277c0c90e0a 100644 (file)
@@ -33,7 +33,7 @@ class ModuleModesOnOper : public Module
        }
 
 
-       virtual void OnRehash(User* user, const std::string &parameter)
+       virtual void OnRehash(User* user)
        {
                delete Conf;
                Conf = new ConfigReader(ServerInstance);
index fc6e7b91f2ce5afa85b70526c92dcd7535c31045..fcb5f1a695f7e6698738a9ea83a0575fc18e8546 100644 (file)
@@ -105,7 +105,7 @@ class ModuleOpermotd : public Module
                        ShowOperMOTD(user);
        }
 
-       virtual void OnRehash(User* user, const std::string &parameter)
+       virtual void OnRehash(User* user)
        {
                LoadOperMOTD();
        }
index 8f0b0aa2d7d384383b7970a83612181d8a8bf6c9..68a3f011527b5201d69a461fa5ddebaa23da429a 100644 (file)
@@ -33,7 +33,7 @@ class ModuleOverride : public Module
                : Module(Me)
        {
                // read our config options (main config file)
-               OnRehash(NULL,"");
+               OnRehash(NULL);
                ServerInstance->SNO->EnableSnomask('G', "GODMODE");
                if (!ServerInstance->Modules->PublishFeature("Override", this))
                {
@@ -45,7 +45,7 @@ class ModuleOverride : public Module
                ServerInstance->Modules->Attach(eventlist, this, 8);
        }
 
-       virtual void OnRehash(User* user, const std::string &parameter)
+       virtual void OnRehash(User* user)
        {
                // on a rehash we delete our classes for good measure and create them again.
                ConfigReader Conf(ServerInstance);
index 68768bae662789e7dda748e1f1a750eb3f6be858..52c8f241cb77382df7fdd016a053f0f8d4479c40 100644 (file)
@@ -85,7 +85,7 @@ class ModuleOperHash : public Module
 
                /* Read the config file first */
 //             Conf = NULL;
-               OnRehash(NULL,"");
+               OnRehash(NULL);
 
                /* Find all modules which implement the interface 'HashRequest' */
                modulelist* ml = ServerInstance->Modules->FindInterface("HashRequest");
index e553ee2c121d271a247688690f20fc0272f5d15c..ff269934e6fd111b434ca8d7caaa9fc14d006531 100644 (file)
@@ -91,7 +91,7 @@ public:
                Implementation eventlist[] = { I_OnChannelPreDelete };
                ServerInstance->Modules->Attach(eventlist, this, 1);
 
-               OnRehash(NULL, "");
+               OnRehash(NULL);
        }
 
        virtual ~ModulePermanentChannels()
@@ -100,7 +100,7 @@ public:
                delete p;
        }
 
-       virtual void OnRehash(User *user, const std::string &parameter)
+       virtual void OnRehash(User *user)
        {
                /*
                 * Process config-defined list of permanent channels.
index 573567c949948c8746fb57f555338c9cb44cc5d7..6e5eaae46770eaa764ac26a7128039e9d4d7db31 100644 (file)
@@ -251,7 +251,7 @@ class ModuleRemove : public Module
                mycommand2 = new CommandFpart(ServerInstance, supportnokicks);
                ServerInstance->AddCommand(mycommand);
                ServerInstance->AddCommand(mycommand2);
-               OnRehash(NULL,"");
+               OnRehash(NULL);
                Implementation eventlist[] = { I_On005Numeric, I_OnRehash };
                ServerInstance->Modules->Attach(eventlist, this, 2);
        }
@@ -262,7 +262,7 @@ class ModuleRemove : public Module
                output.append(" REMOVE");
        }
 
-       virtual void OnRehash(User* user, const std::string&)
+       virtual void OnRehash(User* user)
        {
                ConfigReader conf(ServerInstance);
                supportnokicks = conf.ReadFlag("remove", "supportnokicks", 0);
index f4b5b03b046da5ac3bd497f49ff2a85327995955..f84d9abb2a2cc71b2feb721b37397012ee22ff56 100644 (file)
@@ -45,7 +45,7 @@ class ModuleRestrictChans : public Module
                ServerInstance->Modules->Attach(eventlist, this, 2);
        }
 
-       virtual void OnRehash(User* user, const std::string &parameter)
+       virtual void OnRehash(User* user)
        {
                ReadConfig();
        }
index 2394efaa37c7bec2103ea2fa2ebc3b3486f79e9e..9d090ec2ed45e1f08dd59e64bd464d5801930346 100644 (file)
@@ -195,7 +195,7 @@ class ModuleRLine : public Module
        ModuleRLine(InspIRCd* Me) : Module(Me)
        {
                mymodule = this;
-               OnRehash(NULL, "");
+               OnRehash(NULL);
 
                Me->Modules->UseInterface("RegularExpression");
 
@@ -235,7 +235,7 @@ class ModuleRLine : public Module
                }
        }
 
-       virtual void OnRehash(User *user, const std::string &parameter)
+       virtual void OnRehash(User *user)
        {
                ConfigReader Conf(ServerInstance);
 
index 7a7fe742a0ee5a318c356281e5c39224f5a32dd7..b99c78c8385a30bd5d339a07641e149a12c0190e 100644 (file)
@@ -40,7 +40,7 @@ class ModuleSafeList : public Module
  public:
        ModuleSafeList(InspIRCd* Me) : Module(Me)
        {
-               OnRehash(NULL, "");
+               OnRehash(NULL);
                Implementation eventlist[] = { I_OnBufferFlushed, I_OnPreCommand, I_OnCleanup, I_OnUserQuit, I_On005Numeric, I_OnRehash };
                ServerInstance->Modules->Attach(eventlist, this, 6);
        }
@@ -49,7 +49,7 @@ class ModuleSafeList : public Module
        {
        }
 
-       virtual void OnRehash(User* user, const std::string &parameter)
+       virtual void OnRehash(User* user)
        {
                ConfigReader MyConf(ServerInstance);
                ThrottleSecs = MyConf.ReadInteger("safelist", "throttle", "60", 0, true);
index 877d863e5e9e98c5598fcae8108bf4eda840a24a..6c3114860fab1688dd559e3ff5579003eed9484c 100644 (file)
@@ -23,7 +23,7 @@ class ModuleSecureList : public Module
  public:
        ModuleSecureList(InspIRCd* Me) : Module(Me)
        {
-               OnRehash(NULL,"");
+               OnRehash(NULL);
                Implementation eventlist[] = { I_OnRehash, I_OnPreCommand, I_On005Numeric };
                ServerInstance->Modules->Attach(eventlist, this, 3);
        }
@@ -37,7 +37,7 @@ class ModuleSecureList : public Module
                return Version("$Id$",VF_VENDOR,API_VERSION);
        }
 
-       void OnRehash(User* user, const std::string &parameter)
+       void OnRehash(User* user)
        {
                ConfigReader* MyConf = new ConfigReader(ServerInstance);
                allowlist.clear();
index 91c005bee381b4cf3620830e9018b7280db4b7c9..6fc6989f8f5ae06b9250171edd13990f14119af9 100644 (file)
@@ -70,7 +70,7 @@ class ModuleSetHost : public Module
        ModuleSetHost(InspIRCd* Me)
                : Module(Me)
        {
-               OnRehash(NULL,"");
+               OnRehash(NULL);
                mycommand = new CommandSethost(ServerInstance, hostmap);
                ServerInstance->AddCommand(mycommand);
                Implementation eventlist[] = { I_OnRehash };
@@ -78,7 +78,7 @@ class ModuleSetHost : public Module
        }
 
 
-       void OnRehash(User* user, const std::string &parameter)
+       void OnRehash(User* user)
        {
                ConfigReader Conf(ServerInstance);
                std::string hmap = Conf.ReadValue("hostname", "charmap", 0);
index 56c57aee0e2245d591e9a4d216bae788c72b388b..939807bd3f663ee8253cf0e21be16dbb7d51f184 100644 (file)
@@ -191,7 +191,7 @@ class ModuleShun : public Module
 
                Implementation eventlist[] = { I_OnStats, I_OnPreCommand, I_OnUserConnect, I_OnRehash };
                ServerInstance->Modules->Attach(eventlist, this, 4);
-               OnRehash(NULL, "");
+               OnRehash(NULL);
        }
 
        virtual ~ModuleShun()
@@ -209,7 +209,7 @@ class ModuleShun : public Module
                return 1;
        }
 
-       virtual void OnRehash(User* user, const std::string &parameter)
+       virtual void OnRehash(User* user)
        {
                ConfigReader MyConf(ServerInstance);
                std::string cmds = MyConf.ReadValue("shun", "enabledcommands", 0);
index f938d07d6bd101e8f0f23b6713dbca1aa79d3b62..9b5f393e57b838cf99a32b1a8c41c9145b9f5fd3 100644 (file)
@@ -274,7 +274,7 @@ class ModuleSilence : public Module
        ModuleSilence(InspIRCd* Me)
                : Module(Me), maxsilence(32)
        {
-               OnRehash(NULL, "");
+               OnRehash(NULL);
                cmdsilence = new CommandSilence(ServerInstance,maxsilence);
                cmdsvssilence = new CommandSVSSilence(ServerInstance);
                ServerInstance->AddCommand(cmdsilence);
@@ -284,7 +284,7 @@ class ModuleSilence : public Module
                ServerInstance->Modules->Attach(eventlist, this, 7);
        }
 
-       virtual void OnRehash(User* user, const std::string &parameter)
+       virtual void OnRehash(User* user)
        {
                ConfigReader Conf(ServerInstance);
                maxsilence = Conf.ReadInteger("silence", "maxentries", 0, true);
index 37ed06c3ad316b36ed4c830f4f35b73238b64961..45aea56ecaff11096f3b55aff12166e595e238a1 100644 (file)
@@ -50,11 +50,11 @@ ModuleSpanningTree::ModuleSpanningTree(InspIRCd* Me)
                I_OnPreCommand, I_OnGetServerDescription, I_OnUserInvite, I_OnPostLocalTopicChange,
                I_OnWallops, I_OnUserNotice, I_OnUserMessage, I_OnBackgroundTimer,
                I_OnUserJoin, I_OnChangeLocalUserHost, I_OnChangeName, I_OnUserPart, I_OnUnloadModule,
-               I_OnUserQuit, I_OnUserPostNick, I_OnUserKick, I_OnRemoteKill, I_OnRehash,
+               I_OnUserQuit, I_OnUserPostNick, I_OnUserKick, I_OnRemoteKill, I_OnRehash, I_OnPreRehash,
                I_OnOper, I_OnAddLine, I_OnDelLine, I_ProtoSendMode, I_OnMode, I_OnLoadModule,
                I_OnStats, I_ProtoSendMetaData, I_OnEvent, I_OnSetAway, I_OnPostCommand
        };
-       ServerInstance->Modules->Attach(eventlist, this, 29);
+       ServerInstance->Modules->Attach(eventlist, this, 30);
 
        delete ServerInstance->PI;
        ServerInstance->PI = new SpanningTreeProtocolInterface(this, Utils, ServerInstance);
@@ -706,19 +706,21 @@ void ModuleSpanningTree::OnRemoteKill(User* source, User* dest, const std::strin
        Utils->DoOneToMany(source->uuid,"KILL",params);
 }
 
-void ModuleSpanningTree::OnRehash(User* user, const std::string &parameter)
+void ModuleSpanningTree::OnPreRehash(User* user, const std::string &parameter)
 {
        ServerInstance->Logs->Log("remoterehash", DEBUG, "called with param %s", parameter.c_str());
 
        // Send out to other servers
        if (!parameter.empty() && parameter[0] != '-')
        {
-               ServerInstance->Logs->Log("remoterehash", DEBUG, "sending out lol");
                std::deque<std::string> params;
                params.push_back(parameter);
                Utils->DoOneToAllButSender(user ? user->uuid : ServerInstance->Config->GetSID(), "REHASH", params, user ? user->server : ServerInstance->Config->ServerName);
        }
+}
 
+void ModuleSpanningTree::OnRehash(User* user)
+{
        // Re-read config stuff
        Utils->ReadConfiguration(true);
 }
index 5333b64d46df2940d4df5fc4ff121fe2708d81e6..3935c3dd6e0e9b5db35700f537839f7ede81bfa6 100644 (file)
@@ -173,7 +173,8 @@ class ModuleSpanningTree : public Module
        virtual void OnUserPostNick(User* user, const std::string &oldnick);
        virtual void OnUserKick(User* source, User* user, Channel* chan, const std::string &reason, bool &silent);
        virtual void OnRemoteKill(User* source, User* dest, const std::string &reason, const std::string &operreason);
-       virtual void OnRehash(User* user, const std::string &parameter);
+       virtual void OnPreRehash(User* user, const std::string &parameter);
+       virtual void OnRehash(User* user);
        virtual void OnOper(User* user, const std::string &opertype);
        void OnLine(User* source, const std::string &host, bool adding, char linetype, long duration, const std::string &reason);
        virtual void OnAddLine(User *u, XLine *x);
index b750d839d563f42c94865bd9fccb8afd5ee1071b..da8e1b6c4804fd75a1c8a26d0c731a5994841b50 100644 (file)
@@ -95,7 +95,7 @@ class ModuleSWhois : public Module
                ServerInstance->Modules->Attach(eventlist, this, 7);
        }
 
-       void OnRehash(User* user, const std::string &parameter)
+       void OnRehash(User* user)
        {
                delete Conf;
                Conf = new ConfigReader(ServerInstance);
index b7f4114ddb591fac577ab92efebe9c4d0a698bf3..eda1b74a397d7080a9c8af5d235f54d92fa06b87 100644 (file)
@@ -375,7 +375,7 @@ class Modulewatch : public Module
        Modulewatch(InspIRCd* Me)
                : Module(Me), maxwatch(32)
        {
-               OnRehash(NULL, "");
+               OnRehash(NULL);
                whos_watching_me = new watchentries();
                mycommand = new CommandWatch(ServerInstance, maxwatch);
                ServerInstance->AddCommand(mycommand);
@@ -385,7 +385,7 @@ class Modulewatch : public Module
                ServerInstance->Modules->Attach(eventlist, this, 8);
        }
 
-       virtual void OnRehash(User* user, const std::string &parameter)
+       virtual void OnRehash(User* user)
        {
                ConfigReader Conf(ServerInstance);
                maxwatch = Conf.ReadInteger("watch", "maxentries", 0, true);
index 5000d32d91a0317986ef5b9df333173ca21e1d76..1c73067b7307bf4d098a4fd3fa13a61575a3405e 100644 (file)
@@ -54,7 +54,6 @@ void RehashHandler::Call(const std::string &reason)
        if (!Server->ConfigThread)
        {
                Server->Config->RehashUserUID = "";
-               Server->Config->RehashParameter = "";
 
                Server->ConfigThread = new ConfigReaderThread(Server, false, "");
                Server->Threads->Start(Server->ConfigThread);