summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/modules/m_filter.h8
1 files changed, 8 insertions, 0 deletions
diff --git a/src/modules/m_filter.h b/src/modules/m_filter.h
index ba52ce70b..d21c8fc9c 100644
--- a/src/modules/m_filter.h
+++ b/src/modules/m_filter.h
@@ -221,12 +221,20 @@ int FilterBase::OnPreCommand(const std::string &command, const char** parameters
if (command == "QUIT")
{
+ /* QUIT with no reason: nothing to do */
+ if (pcnt < 1)
+ return 0;
+
checkline = parameters[0];
replacepoint = 0;
parting = false;
}
else if (command == "PART")
{
+ /* PART with no reason: nothing to do */
+ if (pcnt < 2)
+ return 0;
+
checkline = parameters[1];
replacepoint = 1;
parting = true;