diff options
-rw-r--r-- | include/configreader.h | 5 | ||||
-rw-r--r-- | src/commands/cmd_die.cpp | 15 | ||||
-rw-r--r-- | src/configreader.cpp | 3 |
3 files changed, 2 insertions, 21 deletions
diff --git a/include/configreader.h b/include/configreader.h index f5ce4b57a..e9bcbdb2c 100644 --- a/include/configreader.h +++ b/include/configreader.h @@ -414,11 +414,6 @@ class CoreExport ServerConfig */ int MaxWhoResults; - /** How many seconds to wait before exiting - * the program when /DIE is correctly issued. - */ - int DieDelay; - /** True if we're going to hide netsplits as *.net *.split for non-opers */ bool HideSplits; diff --git a/src/commands/cmd_die.cpp b/src/commands/cmd_die.cpp index 658240de8..9cc0654a1 100644 --- a/src/commands/cmd_die.cpp +++ b/src/commands/cmd_die.cpp @@ -13,14 +13,6 @@ #include "inspircd.h" -#ifndef __CMD_DIE_H__ -#define __CMD_DIE_H__ - -// include the common header files - -#include "users.h" -#include "channels.h" - /** Handle /DIE. These command handlers can be reloaded by the core, * and handle basic RFC1459 commands. Commands within modules work * the same way, however, they can be fully unloaded, where these @@ -41,8 +33,6 @@ class CommandDie : public Command CmdResult Handle(const std::vector<std::string>& parameters, User *user); }; -#endif - #include "exitcodes.h" /** Handle /DIE @@ -52,14 +42,11 @@ CmdResult CommandDie::Handle (const std::vector<std::string>& parameters, User * if (!ServerInstance->PassCompare(user, ServerInstance->Config->diepass, parameters[0].c_str(), ServerInstance->Config->powerhash)) { { - std::string diebuf = std::string("*** DIE command from ") + user->nick + "!" + user->ident + "@" + user->dhost + ". Terminating in " + ConvToStr(ServerInstance->Config->DieDelay) + " seconds."; + std::string diebuf = std::string("*** DIE command from ") + user->nick + "!" + user->ident + "@" + user->dhost + ". Terminating."; ServerInstance->Logs->Log("COMMAND",SPARSE, diebuf); ServerInstance->SendError(diebuf); } - if (ServerInstance->Config->DieDelay) - sleep(ServerInstance->Config->DieDelay); - ServerInstance->Exit(EXIT_STATUS_DIE); } else diff --git a/src/configreader.cpp b/src/configreader.cpp index 335b2458d..f81283dc7 100644 --- a/src/configreader.cpp +++ b/src/configreader.cpp @@ -37,7 +37,7 @@ ServerConfig::ServerConfig() WhoWasGroupSize = WhoWasMaxGroups = WhoWasMaxKeep = 0; NoUserDns = OperSpyWhois = HideBans = HideSplits = UndernetMsgPrefix = false; CycleHosts = InvBypassModes = true; - dns_timeout = DieDelay = 5; + dns_timeout = 5; MaxTargets = 20; NetBufferSize = 10240; SoftLimit = ServerInstance->SE->GetMaxFds(); @@ -431,7 +431,6 @@ void ServerConfig::Fill() diepass = ConfValue("power")->getString("diepass"); restartpass = ConfValue("power")->getString("restartpass"); powerhash = ConfValue("power")->getString("hash"); - DieDelay = ConfValue("power")->getInt("pause"); PrefixQuit = options->getString("prefixquit"); SuffixQuit = options->getString("suffixquit"); FixedQuit = options->getString("fixedquit"); |