summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorattilamolnar <attilamolnar@hush.com>2013-01-02 19:01:57 +0100
committerattilamolnar <attilamolnar@hush.com>2013-01-02 19:01:57 +0100
commit3988e9779e95c4d758a489ca4dc49138a0a0f26f (patch)
tree9861ebf4d003ca2da03420daf94e2102e48e69fb
parent9cd47a421dd7a1b5bb155091fd4173e95ed8da55 (diff)
m_messageflood Ask to be the last to handle OnUserPreMessage/OnUserPreNotice
Fixes #394 reported by @JDowny
-rw-r--r--src/modules/m_messageflood.cpp5
1 files changed, 4 insertions, 1 deletions
diff --git a/src/modules/m_messageflood.cpp b/src/modules/m_messageflood.cpp
index 814eee5ef..9ff17924d 100644
--- a/src/modules/m_messageflood.cpp
+++ b/src/modules/m_messageflood.cpp
@@ -188,8 +188,11 @@ class ModuleMsgFlood : public Module
return MOD_RES_PASSTHRU;
}
- ~ModuleMsgFlood()
+ void Prioritize()
{
+ // we want to be after all modules that might deny the message (e.g. m_muteban, m_noctcp, m_blockcolor, etc.)
+ ServerInstance->Modules->SetPriority(this, I_OnUserPreMessage, PRIORITY_LAST);
+ ServerInstance->Modules->SetPriority(this, I_OnUserPreNotice, PRIORITY_LAST);
}
Version GetVersion()