diff options
Diffstat (limited to 'src/users.cpp')
| -rw-r--r-- | src/users.cpp | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/src/users.cpp b/src/users.cpp index 06bd58421..b5ce7cd91 100644 --- a/src/users.cpp +++ b/src/users.cpp @@ -83,6 +83,7 @@ User::User(const std::string& uid, Server* srv, Type type) , server(srv) , registered(REG_NONE) , quitting(false) + , uniqueusername(false) , usertype(type) { client_sa.sa.sa_family = AF_UNSPEC; @@ -521,6 +522,7 @@ void LocalUser::CheckClass(bool clone_count) } this->nextping = ServerInstance->Time() + a->GetPingTime(); + this->uniqueusername = a->uniqueusername; } bool LocalUser::CheckLines(bool doZline) @@ -686,6 +688,12 @@ const std::string& User::GetIPString() return cachedip; } +const std::string& User::GetBanIdent() const +{ + static const std::string wildcard = "*"; + return uniqueusername ? ident : wildcard; +} + const std::string& User::GetHost(bool uncloak) const { return uncloak ? GetRealHost() : GetDisplayedHost(); |
