]> git.netwichtig.de Git - user/henk/code/inspircd.git/blobdiff - src/server.cpp
...and make it not go querying modules that dont implement the right interface and...
[user/henk/code/inspircd.git] / src / server.cpp
index c3efc7e6b2b8c95873aa807420505bb511766657..75e404b802885d578b9e3ae2d1554047daf148b7 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
@@ -48,6 +48,7 @@ void InspIRCd::Exit(int status)
 
 void RehashHandler::Call(const std::string &reason)
 {
+       Server->RehashFinishMutex->Lock();
        Server->SNO->WriteToSnoMask('A', "Rehashing config file %s %s",ServerConfig::CleanFilename(Server->ConfigFileName), reason.c_str());
        Server->RehashUsersAndChans();
        FOREACH_MOD_I(Server, I_OnGarbageCollect, OnGarbageCollect());
@@ -59,6 +60,7 @@ void RehashHandler::Call(const std::string &reason)
                Server->ConfigThread = new ConfigReaderThread(Server, false, "");
                Server->Threads->Create(Server->ConfigThread);
        }
+       Server->RehashFinishMutex->Unlock();
 }
 
 void InspIRCd::RehashServer()