summaryrefslogtreecommitdiff
path: root/src/usermanager.cpp
diff options
context:
space:
mode:
authorbrain <brain@e03df62e-2008-0410-955e-edbf42e46eb7>2008-04-02 17:32:45 +0000
committerbrain <brain@e03df62e-2008-0410-955e-edbf42e46eb7>2008-04-02 17:32:45 +0000
commite66e07d53efd2889e5954d30327343482d550a84 (patch)
tree45cb40ed0a78c08f005f37f1f9b7f529c645302e /src/usermanager.cpp
parent4e078ed34b70fc780886a8412f891ca9540d7622 (diff)
Remove MAXCLIENTS, this is supported at runtime by the softlimit anyway.
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@9265 e03df62e-2008-0410-955e-edbf42e46eb7
Diffstat (limited to 'src/usermanager.cpp')
-rw-r--r--src/usermanager.cpp5
1 files changed, 2 insertions, 3 deletions
diff --git a/src/usermanager.cpp b/src/usermanager.cpp
index 6a23ad795..59ac3fce9 100644
--- a/src/usermanager.cpp
+++ b/src/usermanager.cpp
@@ -108,7 +108,7 @@ void UserManager::AddClient(InspIRCd* Instance, int socket, int port, bool iscac
this->local_users.push_back(New);
- if ((this->local_users.size() > Instance->Config->SoftLimit) || (this->local_users.size() >= MAXCLIENTS))
+ if ((this->local_users.size() > Instance->Config->SoftLimit) || (this->local_users.size() >= Instance->SE->GetMaxFds()))
{
Instance->SNO->WriteToSnoMask('A', "Warning: softlimit value has been reached: %d clients", Instance->Config->SoftLimit);
User::QuitUser(Instance, New,"No more connections allowed");
@@ -125,13 +125,12 @@ void UserManager::AddClient(InspIRCd* Instance, int socket, int port, bool iscac
* which for the time being is a physical impossibility (even the largest networks dont have more
* than about 10,000 users on ONE server!)
*/
-#ifndef WINDOWS
if (socket >= Instance->SE->GetMaxFds())
{
User::QuitUser(Instance, New, "Server is full");
return;
}
-#endif
+
/*
* even with bancache, we still have to keep User::exempt current.
* besides that, if we get a positive bancache hit, we still won't fuck