Fix dynamic user limit settings

PR #2220 removed the ability to be able to change the max user limit
count while the server is running requiring a restart to make the
settings change.  This PR reverts the behavior back to how it operated
prior to the PR.
This commit is contained in:
woogerboy21
2016-10-24 00:30:58 -04:00
parent b808d3824b
commit 749bc5d6f5
4 changed files with 16 additions and 8 deletions

View File

@@ -384,7 +384,7 @@ Response::ResponseCode Server_ProtocolHandler::cmdPing(const Command_Ping & /*cm
Response::ResponseCode Server_ProtocolHandler::cmdLogin(const Command_Login &cmd, ResponseContainer &rc)
{
// limit the number of users that can connect to the server based on configuration settings
if (server->getmaxUserLimitEnabled()) {
if (server->getMaxUserLimitEnabled()) {
if (server->getUsersCount() >= server->getMaxUserLimit()) {
qDebug() << "Max Users Total Limit Reached, please increase the max_users_total setting.";
return Response::RespServerFull;