diff options
author | Adam <adam@sigterm.info> | 2013-04-26 22:13:03 -0700 |
---|---|---|
committer | Adam <adam@sigterm.info> | 2013-04-26 22:13:03 -0700 |
commit | 370e899d8a53ecfd3ec3a49a5fbb81212fa154e3 (patch) | |
tree | 06b001530ef64b7a78d271197cf838a2760edfef /src/commands | |
parent | 79e462c530a4617d688ca3c648ece2d8ebb7396a (diff) | |
parent | f2566ff550bc3516eb35fab76217384866de8bcb (diff) |
Merge pull request #501 from SaberUK/master+nouserdns
Move <performance:nouserdns> to <connect:nouserdns>.
Diffstat (limited to 'src/commands')
-rw-r--r-- | src/commands/cmd_hostname_lookup.cpp | 10 |
1 files changed, 2 insertions, 8 deletions
diff --git a/src/commands/cmd_hostname_lookup.cpp b/src/commands/cmd_hostname_lookup.cpp index 04592c6e5..d43730b94 100644 --- a/src/commands/cmd_hostname_lookup.cpp +++ b/src/commands/cmd_hostname_lookup.cpp @@ -177,7 +177,6 @@ class UserResolver : public DNS::Request class ModuleHostnameLookup : public Module { - bool nouserdns; LocalIntExt dnsLookup; LocalStringExt ptrHosts; dynamic_reference<DNS::Manager> DNS; @@ -198,18 +197,13 @@ class ModuleHostnameLookup : public Module ServerInstance->Modules->AddService(this->dnsLookup); ServerInstance->Modules->AddService(this->ptrHosts); - Implementation i[] = { I_OnUserInit, I_OnCheckReady, I_OnRehash }; + Implementation i[] = { I_OnUserInit, I_OnCheckReady }; ServerInstance->Modules->Attach(i, this, sizeof(i) / sizeof(Implementation)); } - void OnRehash(User* user) - { - nouserdns = ServerInstance->Config->ConfValue("performance")->getBool("nouserdns"); - } - void OnUserInit(LocalUser *user) { - if (!DNS || nouserdns) + if (!DNS || user->MyClass->nouserdns) { user->WriteServ("NOTICE %s :*** Skipping host resolution (disabled by server administrator)", user->nick.c_str()); return; |