mirror of
https://github.com/anope/anope.git
synced 2026-07-03 23:23:13 +02:00
Made MOD_STOP returned from commands really halt processing (stops OnPostCommand event being called)
git-svn-id: http://anope.svn.sourceforge.net/svnroot/anope/trunk@2565 5417fbe8-f217-4b02-8779-1006273d7864
This commit is contained in:
+5
-2
@@ -52,7 +52,7 @@ Command *lookup_cmd(Command * list, char *cmd)
|
||||
void mod_run_cmd(char *service, User * u, CommandHash * cmdTable[], const char *cmd)
|
||||
{
|
||||
Command *c = findCommand(cmdTable, cmd);
|
||||
int retVal = 0;
|
||||
int retVal = MOD_CONT;
|
||||
ChannelInfo *ci;
|
||||
|
||||
if (!c)
|
||||
@@ -174,7 +174,10 @@ void mod_run_cmd(char *service, User * u, CommandHash * cmdTable[], const char *
|
||||
|
||||
retVal = c->Execute(u, params);
|
||||
|
||||
FOREACH_MOD(I_OnPostCommand, OnPostCommand(u, c->service, c->name.c_str(), params));
|
||||
if (retVal == MOD_CONT)
|
||||
{
|
||||
FOREACH_MOD(I_OnPostCommand, OnPostCommand(u, c->service, c->name.c_str(), params));
|
||||
}
|
||||
}
|
||||
|
||||
/*************************************************************************/
|
||||
|
||||
Reference in New Issue
Block a user