diff options
author | brain <brain@e03df62e-2008-0410-955e-edbf42e46eb7> | 2005-11-30 15:35:15 +0000 |
---|---|---|
committer | brain <brain@e03df62e-2008-0410-955e-edbf42e46eb7> | 2005-11-30 15:35:15 +0000 |
commit | 5a331966832a930d4770752f5e60338581830887 (patch) | |
tree | 484adbd474ba9b0f206b89e31969b245221f570a /src | |
parent | 596e41348f06cab088e35c362393a3140bf161b0 (diff) |
Added Server::RehashServer
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@2060 e03df62e-2008-0410-955e-edbf42e46eb7
Diffstat (limited to 'src')
-rw-r--r-- | src/commands.cpp | 5 | ||||
-rw-r--r-- | src/inspircd.cpp | 2 | ||||
-rw-r--r-- | src/modules.cpp | 6 |
3 files changed, 11 insertions, 2 deletions
diff --git a/src/commands.cpp b/src/commands.cpp index 518ecd71e..82a6a2237 100644 --- a/src/commands.cpp +++ b/src/commands.cpp @@ -1076,7 +1076,10 @@ void handle_rehash(char **parameters, int pcnt, userrec *user) { WriteServ(user->fd,"382 %s %s :Rehashing",user->nick,CleanFilename(CONFIG_FILE)); ReadConfig(false,user); - FOREACH_MOD OnRehash(); + std::string parameter = ""; + if (pcnt) + parameter = parameters[0]; + FOREACH_MOD OnRehash(parameter); WriteOpers("%s is rehashing config file %s",user->nick,CleanFilename(CONFIG_FILE)); } diff --git a/src/inspircd.cpp b/src/inspircd.cpp index dd151283a..a946abbbb 100644 --- a/src/inspircd.cpp +++ b/src/inspircd.cpp @@ -293,7 +293,7 @@ void ReadConfig(bool bail, userrec* user) } else { - WriteOpers("There were errors in the configuration file:",user->nick); + WriteOpers("There were errors in the configuration file:"); while (!errstr.eof()) { errstr.getline(dataline,1024); diff --git a/src/modules.cpp b/src/modules.cpp index a1c9ca811..0541c266d 100644 --- a/src/modules.cpp +++ b/src/modules.cpp @@ -384,6 +384,12 @@ void Server::AddSocket(InspSocket* sock) module_sockets.push_back(sock); } +void Server::RehashServer() +{ + WriteOpers("*** Rehashing config file"); + ReadConfig(false,NULL); +} + void Server::DelSocket(InspSocket* sock) { for (std::vector<InspSocket*>::iterator a = module_sockets.begin(); a < module_sockets.end(); a++) |