]> git.netwichtig.de Git - user/henk/code/inspircd.git/blobdiff - src/commands/cmd_rehash.cpp
Forward port r11094:
[user/henk/code/inspircd.git] / src / commands / cmd_rehash.cpp
index cab5934572b01433ad778833213508fef700e913..162590cf8e5f1be4df6ac454222d235d0ee1f34f 100644 (file)
@@ -2,7 +2,7 @@
  *       | Inspire Internet Relay Chat Daemon |
  *       +------------------------------------+
  *
- *  InspIRCd: (C) 2002-2008 InspIRCd Development Team
+ *  InspIRCd: (C) 2002-2009 InspIRCd Development Team
  * See: http://www.inspircd.org/wiki/index.php/Credits
  *
  * This program is free but copyrighted software; see
@@ -28,7 +28,7 @@ CmdResult CommandRehash::Handle (const std::vector<std::string>& parameters, Use
 
        if (parameters.size() && parameters[0][0] != '-')
        {
-               if (!ServerInstance->MatchText(ServerInstance->Config->ServerName, parameters[0]))
+               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
@@ -64,10 +64,10 @@ CmdResult CommandRehash::Handle (const std::vector<std::string>& parameters, Use
 
        if (!ServerInstance->ConfigThread)
        {
-               ServerInstance->Config->RehashUser = user;
+               ServerInstance->Config->RehashUserUID = user->uuid;
                ServerInstance->Config->RehashParameter = parameters.size() ? parameters[0] : "";
 
-               ServerInstance->ConfigThread = new ConfigReaderThread(ServerInstance, false, user);
+               ServerInstance->ConfigThread = new ConfigReaderThread(ServerInstance, false, ServerInstance->Config->RehashUserUID);
                ServerInstance->Threads->Create(ServerInstance->ConfigThread);
        }
        else