diff options
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++) |