diff options
| author | 2005-12-21 20:33:32 +0000 | |
|---|---|---|
| committer | 2005-12-21 20:33:32 +0000 | |
| commit | 0fad2325b495aea5302abce3d9c3f0bd0720281e (patch) | |
| tree | f2ee4065b8232fa9b976141aa9aa83aa04177d68 /src/command_parse.cpp | |
| parent | Added more verbose error output during link (diff) | |
Improved m_alias to only capture complete commands and rewrite them (bug #92 as reported by strike)
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@2601 e03df62e-2008-0410-955e-edbf42e46eb7
Diffstat (limited to 'src/command_parse.cpp')
| -rw-r--r-- | src/command_parse.cpp | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/src/command_parse.cpp b/src/command_parse.cpp index 6f927e89a..7c26ffe61 100644 --- a/src/command_parse.cpp +++ b/src/command_parse.cpp @@ -525,6 +525,11 @@ void CommandParser::ProcessCommand(userrec *user, char* cmd) { /* activity resets the ping pending timer */ user->nping = TIME + user->pingmax; + int MOD_RESULT = 0; + FOREACH_RESULT(OnPreCommand(command,command_p,items,user,false)); + if (MOD_RESULT == 1) { + return; + } if ((items) < cmdlist[i]->min_params) { log(DEBUG,"not enough parameters: %s %s",user->nick,command); @@ -581,7 +586,7 @@ void CommandParser::ProcessCommand(userrec *user, char* cmd) } int MOD_RESULT = 0; - FOREACH_RESULT(OnPreCommand(command,command_p,items,user)); + FOREACH_RESULT(OnPreCommand(command,command_p,items,user,true)); if (MOD_RESULT == 1) { return; } |
