mirror of
https://github.com/inspircd/inspircd.git
synced 2025-03-10 19:19:02 -04:00
Last commit of that batch: Fix some returncodes (some stuff here really didn't need to be routed), clarify a few in comments, and also add some todos for myself next.
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@6978 e03df62e-2008-0410-955e-edbf42e46eb7
This commit is contained in:
parent
e1f34688d6
commit
9c3a20c151
@ -53,7 +53,8 @@ class cmd_alltime : public command_t
|
||||
Event ev((char *) ¶ms, NULL, "send_push");
|
||||
ev.Send(ServerInstance);
|
||||
}
|
||||
|
||||
|
||||
/* we want this routed out! */
|
||||
return CMD_SUCCESS;
|
||||
}
|
||||
};
|
||||
|
@ -111,6 +111,7 @@ class cmd_cban : public command_t
|
||||
}
|
||||
}
|
||||
|
||||
/* we want this routed! */
|
||||
return CMD_SUCCESS;
|
||||
}
|
||||
};
|
||||
|
@ -190,7 +190,8 @@ class cmd_dccallow : public command_t
|
||||
{
|
||||
user->WriteServ("994 %s %s :Added %s to DCCALLOW list for this session", user->nick, user->nick, target->nick);
|
||||
}
|
||||
|
||||
|
||||
/* route it. */
|
||||
return CMD_SUCCESS;
|
||||
}
|
||||
}
|
||||
|
@ -50,6 +50,7 @@ class cmd_devoice : public command_t
|
||||
ServerInstance->SendMode(modes,3,n);
|
||||
delete n;
|
||||
|
||||
/* route it */
|
||||
return CMD_SUCCESS;
|
||||
}
|
||||
|
||||
|
@ -36,11 +36,14 @@ class cmd_gloadmodule : public command_t
|
||||
{
|
||||
ServerInstance->WriteOpers("*** NEW MODULE '%s' GLOBALLY LOADED BY '%s'",parameters[0],user->nick);
|
||||
user->WriteServ("975 %s %s :Module successfully loaded.",user->nick, parameters[0]);
|
||||
|
||||
/* route it! */
|
||||
return CMD_SUCCESS;
|
||||
}
|
||||
else
|
||||
{
|
||||
user->WriteServ("974 %s %s :Failed to load module: %s",user->nick, parameters[0],ServerInstance->ModuleError());
|
||||
/* XXX - returning CMD_FAILURE here could potentially mean half the net loads it, half doesn't. pass it on anyway? -- w00t */
|
||||
return CMD_FAILURE;
|
||||
}
|
||||
}
|
||||
@ -63,10 +66,12 @@ class cmd_gunloadmodule : public command_t
|
||||
{
|
||||
ServerInstance->WriteOpers("*** MODULE '%s' GLOBALLY UNLOADED BY '%s'",parameters[0],user->nick);
|
||||
user->WriteServ("973 %s %s :Module successfully unloaded.",user->nick, parameters[0]);
|
||||
/* route it! */
|
||||
return CMD_SUCCESS;
|
||||
}
|
||||
else
|
||||
{
|
||||
/* XXX - see above note about returning CMD_FAILURE here -- w00t */
|
||||
user->WriteServ("972 %s %s :Failed to unload module: %s",user->nick, parameters[0],ServerInstance->ModuleError());
|
||||
return CMD_FAILURE;
|
||||
}
|
||||
|
@ -42,6 +42,7 @@ class cmd_globops : public command_t
|
||||
}
|
||||
ServerInstance->SNO->WriteToSnoMask('g',line);
|
||||
|
||||
/* route it (ofc :p) */
|
||||
return CMD_SUCCESS;
|
||||
}
|
||||
};
|
||||
|
@ -41,6 +41,7 @@ class cmd_nicklock : public command_t
|
||||
irc::string server;
|
||||
irc::string me;
|
||||
|
||||
/* XXX - these ifs look damn ugly, note to myself to fix them -- w00t */
|
||||
if (source)
|
||||
{
|
||||
if (source->GetExt("nick_locked", dummy))
|
||||
@ -59,6 +60,7 @@ class cmd_nicklock : public command_t
|
||||
}
|
||||
source->Extend("nick_locked", "ON");
|
||||
|
||||
/* route */
|
||||
return CMD_SUCCESS;
|
||||
}
|
||||
|
||||
|
@ -29,14 +29,18 @@ CmdResult ShowOperMOTD(userrec* user)
|
||||
user->WriteServ(std::string("425 ") + user->nick + std::string(" :OPERMOTD file is missing"));
|
||||
return CMD_FAILURE;
|
||||
}
|
||||
|
||||
user->WriteServ(std::string("375 ") + user->nick + std::string(" :- IRC Operators Message of the Day"));
|
||||
|
||||
for(int i=0; i != opermotd->FileSize(); i++)
|
||||
{
|
||||
user->WriteServ(std::string("372 ") + user->nick + std::string(" :- ") + opermotd->GetLine(i));
|
||||
}
|
||||
|
||||
user->WriteServ(std::string("376 ") + user->nick + std::string(" :- End of OPERMOTD"));
|
||||
|
||||
return CMD_SUCCESS;
|
||||
/* don't route me */
|
||||
return CMD_LOCALONLY;
|
||||
}
|
||||
|
||||
/** Handle /OPERMOTD
|
||||
|
@ -52,7 +52,8 @@ class cmd_randquote : public command_t
|
||||
user->WriteServ("NOTICE %s :Your administrator specified an invalid quotes file, please bug them about this.", user->nick);
|
||||
return CMD_FAILURE;
|
||||
}
|
||||
return CMD_SUCCESS;
|
||||
|
||||
return CMD_LOCALONLY;
|
||||
}
|
||||
};
|
||||
|
||||
|
@ -201,6 +201,7 @@ class RemoveBase
|
||||
return CMD_FAILURE;
|
||||
}
|
||||
|
||||
/* route me */
|
||||
return CMD_SUCCESS;
|
||||
}
|
||||
};
|
||||
|
@ -45,7 +45,7 @@ class cmd_setidle : public command_t
|
||||
ServerInstance->WriteOpers(std::string(user->nick)+" used SETIDLE to set their idle time to "+ConvToStr(atoi(parameters[0]))+" seconds");
|
||||
user->WriteServ("944 %s :Idle time set.",user->nick);
|
||||
|
||||
return CMD_SUCCESS;
|
||||
return CMD_LOCALONLY;
|
||||
}
|
||||
};
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user