X-Git-Url: https://git.netwichtig.de/gitweb/?a=blobdiff_plain;f=src%2Fusers.cpp;h=2871653bb5e16f6d23b40282cf6b09eb01fb1be8;hb=0eabe028e25de0cf5037f523a8df72f1dd7e85bf;hp=9c295caad100c22ad9e51a928bb042c0f3cbfd1a;hpb=97c0e6b4c4e304a1c4e764fc06a7e2663a41743d;p=user%2Fhenk%2Fcode%2Finspircd.git diff --git a/src/users.cpp b/src/users.cpp index 9c295caad..2871653bb 100644 --- a/src/users.cpp +++ b/src/users.cpp @@ -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()); @@ -2051,6 +2051,20 @@ void FakeUser::SetFakeServer(std::string name) this->server = nick.c_str(); } +const std::string FakeUser::GetFullHost() +{ + if (*ServerInstance->Config->HideWhoisServer) + return ServerInstance->Config->HideWhoisServer; + return nick; +} + +const std::string FakeUser::GetFullRealHost() +{ + if (*ServerInstance->Config->HideWhoisServer) + return ServerInstance->Config->HideWhoisServer; + return nick; +} + VisData::VisData() { }