summaryrefslogtreecommitdiff
path: root/src/coremods/core_xline
diff options
context:
space:
mode:
authorAttila Molnar <attilamolnar@hush.com>2014-03-15 15:21:18 +0100
committerAttila Molnar <attilamolnar@hush.com>2014-03-15 15:21:18 +0100
commit66965131f834d14104ad618fd6d89bfd912cd120 (patch)
tree3090eefce9e5ca824edc376dc11f7f17f0a33be9 /src/coremods/core_xline
parentadb26a4e882d317de4e4135f414b7002cafe07a4 (diff)
Add UserManager::GetUsers()
Diffstat (limited to 'src/coremods/core_xline')
-rw-r--r--src/coremods/core_xline/core_xline.cpp2
-rw-r--r--src/coremods/core_xline/core_xline.h2
2 files changed, 2 insertions, 2 deletions
diff --git a/src/coremods/core_xline/core_xline.cpp b/src/coremods/core_xline/core_xline.cpp
index 94183d829..7daa70b49 100644
--- a/src/coremods/core_xline/core_xline.cpp
+++ b/src/coremods/core_xline/core_xline.cpp
@@ -34,7 +34,7 @@ bool InsaneBan::MatchesEveryone(const std::string& mask, MatcherBase& test, User
if (!matches)
return false;
- float percent = ((float)matches / (float)ServerInstance->Users->clientlist->size()) * 100;
+ float percent = ((float)matches / (float)ServerInstance->Users->GetUsers().size()) * 100;
if (percent > itrigger)
{
ServerInstance->SNO->WriteToSnoMask('a', "\2WARNING\2: %s tried to set a %s-line mask of %s, which covers %.2f%% of the network!", user->nick.c_str(), bantype, mask.c_str(), percent);
diff --git a/src/coremods/core_xline/core_xline.h b/src/coremods/core_xline/core_xline.h
index 6101d79bf..d4ad498a0 100644
--- a/src/coremods/core_xline/core_xline.h
+++ b/src/coremods/core_xline/core_xline.h
@@ -38,7 +38,7 @@ class InsaneBan
{
long matches = 0;
const T* c = static_cast<T*>(this);
- const user_hash& users = *ServerInstance->Users->clientlist;
+ const user_hash& users = ServerInstance->Users->GetUsers();
for (user_hash::const_iterator i = users.begin(); i != users.end(); ++i)
{
if (c->Check(i->second, mask))