]> git.netwichtig.de Git - user/henk/code/inspircd.git/blobdiff - src/users.cpp
Patch to not increment nickchange counter for nick changes that would be blocked...
[user/henk/code/inspircd.git] / src / users.cpp
index 5e27469e934508fc9e6e8fb2abdd18863bac7e35..2871653bb5e16f6d23b40282cf6b09eb01fb1be8 100644 (file)
@@ -1865,7 +1865,7 @@ ConnectClass* User::SetClass(const std::string &explicit_name)
                        }
 
                        /* check if host matches.. */
-                       if (!InspIRCd::MatchCIDR(this->GetIPString(), c->GetHost(), NULL) &&
+                       if (c->GetHost().length() && !InspIRCd::MatchCIDR(this->GetIPString(), c->GetHost(), NULL) &&
                            !InspIRCd::MatchCIDR(this->host, c->GetHost(), NULL))
                        {
                                ServerInstance->Logs->Log("CONNECTCLASS", DEBUG, "No host match (for %s)", c->GetHost().c_str());
@@ -2053,14 +2053,14 @@ void FakeUser::SetFakeServer(std::string name)
 
 const std::string FakeUser::GetFullHost()
 {
-       if (ServerInstance->Config->HideWhoisServer)
+       if (*ServerInstance->Config->HideWhoisServer)
                return ServerInstance->Config->HideWhoisServer;
        return nick;
 }
 
 const std::string FakeUser::GetFullRealHost()
 {
-       if (ServerInstance->Config->HideWhoisServer)
+       if (*ServerInstance->Config->HideWhoisServer)
                return ServerInstance->Config->HideWhoisServer;
        return nick;
 }