aboutsummaryrefslogtreecommitdiffstats
path: root/src/usermanager.cpp
diff options
context:
space:
mode:
authorGravatar Sadie Powell2022-07-22 20:44:47 +0100
committerGravatar Sadie Powell2022-07-22 20:44:47 +0100
commitad2aecf19116b1491fa3776e069e1160d4e76927 (patch)
tree02239d304f706c6ea20c1d13c6e041a226230a89 /src/usermanager.cpp
parentRemove use of the deprecated std::iterator type. (diff)
Remove some unnecessary getters in ConnectClass.
All of these members are public anyway.
Diffstat (limited to 'src/usermanager.cpp')
-rw-r--r--src/usermanager.cpp8
1 files changed, 4 insertions, 4 deletions
diff --git a/src/usermanager.cpp b/src/usermanager.cpp
index 96f866f87..2702a19dd 100644
--- a/src/usermanager.cpp
+++ b/src/usermanager.cpp
@@ -67,7 +67,7 @@ namespace
// This user didn't answer the last ping, remove them.
if (!user->lastping)
{
- time_t secs = ServerInstance->Time() - (user->nextping - user->GetClass()->GetPingTime());
+ time_t secs = ServerInstance->Time() - (user->nextping - user->GetClass()->pingtime);
const std::string message = "Ping timeout: " + ConvToStr(secs) + (secs != 1 ? " seconds" : " second");
ServerInstance->Users.QuitUser(user, message);
return;
@@ -77,12 +77,12 @@ namespace
ClientProtocol::Messages::Ping ping;
user->Send(ServerInstance->GetRFCEvents().ping, ping);
user->lastping = 0;
- user->nextping = ServerInstance->Time() + user->GetClass()->GetPingTime();
+ user->nextping = ServerInstance->Time() + user->GetClass()->pingtime;
}
void CheckRegistrationTimeout(LocalUser* user)
{
- if (user->GetClass() && (ServerInstance->Time() > (user->signon + user->GetClass()->GetRegTimeout())))
+ if (user->GetClass() && (ServerInstance->Time() > static_cast<time_t>(user->signon + user->GetClass()->registration_timeout)))
{
// Either the user did not send NICK/USER or a module blocked registration in
// OnCheckReady until the client timed out.
@@ -375,7 +375,7 @@ void UserManager::DoBackgroundUserStuff()
if (curr->CommandFloodPenalty || curr->eh.GetSendQSize())
{
- unsigned long rate = curr->GetClass()->GetCommandRate();
+ unsigned long rate = curr->GetClass()->commandrate;
if (curr->CommandFloodPenalty > rate)
curr->CommandFloodPenalty -= rate;
else