summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/modules/m_connflood.cpp7
1 files changed, 4 insertions, 3 deletions
diff --git a/src/modules/m_connflood.cpp b/src/modules/m_connflood.cpp
index 40d64520f..c834605b0 100644
--- a/src/modules/m_connflood.cpp
+++ b/src/modules/m_connflood.cpp
@@ -70,9 +70,10 @@ public:
virtual int OnUserRegister(userrec* user)
{
time_t next = ServerInstance->Time();
- if (!first)
- first = next - boot_wait;
-
+
+ if ((ServerInstance->startup_time + boot_wait) > next)
+ return 0;
+
/* time difference between first and latest connection */
time_t tdiff = next - first;