summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authordanieldg <danieldg@e03df62e-2008-0410-955e-edbf42e46eb7>2009-05-02 15:01:32 +0000
committerdanieldg <danieldg@e03df62e-2008-0410-955e-edbf42e46eb7>2009-05-02 15:01:32 +0000
commit3ff5e57de4ceca0b3287c826b7b409e5f14196a1 (patch)
tree8f8557f69baa5f4f6552730bb6f06f29c3a7ef00 /src
parentd94394560c090e3bf6ae36202af555e9547e4006 (diff)
Send rehash message to global sno, fixes bug #855. Also only send message when the rehash happens.
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@11344 e03df62e-2008-0410-955e-edbf42e46eb7
Diffstat (limited to 'src')
-rw-r--r--src/commands/cmd_rehash.cpp19
1 files changed, 10 insertions, 9 deletions
diff --git a/src/commands/cmd_rehash.cpp b/src/commands/cmd_rehash.cpp
index e34051611..b58d6035a 100644
--- a/src/commands/cmd_rehash.cpp
+++ b/src/commands/cmd_rehash.cpp
@@ -49,18 +49,19 @@ CmdResult CommandRehash::Handle (const std::vector<std::string>& parameters, Use
ServerInstance->PI->SendUserNotice(user, std::string("*** Rehashing server ") + ServerInstance->ConfigFileName);
- std::string m = user->nick + " is rehashing config file " + ServerConfig::CleanFilename(ServerInstance->ConfigFileName) + " on " + ServerInstance->Config->ServerName;
- ServerInstance->SNO->WriteToSnoMask('a', m);
+ 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);
+
+ /* Don't do anything with the logs here -- logs are restarted
+ * after the config thread has completed.
+ */
- /* Don't do anything with the logs here -- logs are restarted
- * after the config thread has completed.
- */
+ ServerInstance->RehashUsersAndChans();
+ FOREACH_MOD(I_OnGarbageCollect, OnGarbageCollect());
- ServerInstance->RehashUsersAndChans();
- FOREACH_MOD(I_OnGarbageCollect, OnGarbageCollect());
- if (!ServerInstance->ConfigThread)
- {
ServerInstance->Config->RehashUserUID = user->uuid;
ServerInstance->Config->RehashParameter = parameters.size() ? parameters[0] : "";