From 5b91ea259b0c01e2c936f1be8ee1f888d2704aa1 Mon Sep 17 00:00:00 2001 From: w00t Date: Sat, 25 Oct 2008 16:41:12 +0000 Subject: Explain the duplicate OnPreCommand call. git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@10717 e03df62e-2008-0410-955e-edbf42e46eb7 --- src/command_parse.cpp | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'src/command_parse.cpp') diff --git a/src/command_parse.cpp b/src/command_parse.cpp index fd1039088..7204461c2 100644 --- a/src/command_parse.cpp +++ b/src/command_parse.cpp @@ -330,6 +330,10 @@ bool CommandParser::ProcessCommand(User *user, std::string &cmd) command_p.push_back(lparam); } + /* + * We call OnPreCommand here seperately if the command exists, so the magic above can + * truncate to max_params if necessary. -- w00t + */ int MOD_RESULT = 0; FOREACH_RESULT(I_OnPreCommand,OnPreCommand(command, command_p, user, false, cmd)); if (MOD_RESULT == 1) -- cgit v1.2.3