* | Inspire Internet Relay Chat Daemon |
* +------------------------------------+
*
- * InspIRCd: (C) 2002-2007 InspIRCd Development Team
+ * InspIRCd: (C) 2002-2008 InspIRCd Development Team
* See: http://www.inspircd.org/wiki/index.php/Credits
*
* This program is free but copyrighted software; see
TRANSLATE2(TR_TEXT, TR_END);
}
- CmdResult Handle (const char** parameters, int pcnt, User *user)
+ CmdResult Handle (const char* const* parameters, int pcnt, User *user)
{
if (!pcnt)
{
{
// tidy up -- if a user's list is empty, theres no use having it
// hanging around in the user record.
- DELETE(sl);
+ delete sl;
user->Shrink("silence_list");
}
}
OnRehash(NULL, "");
mycommand = new CommandSilence(ServerInstance, maxsilence);
ServerInstance->AddCommand(mycommand);
+ Implementation eventlist[] = { I_OnRehash, I_OnUserQuit, I_On005Numeric, I_OnUserPreNotice, I_OnUserPreMessage };
+ ServerInstance->Modules->Attach(eventlist, this, 5);
}
- void Implements(char* List)
- {
- List[I_OnRehash] = List[I_OnUserQuit] = List[I_On005Numeric] = List[I_OnUserPreNotice] = List[I_OnUserPreMessage] = 1;
- }
virtual void OnRehash(User* user, const std::string ¶meter)
{
user->GetExt("silence_list", sl);
if (sl)
{
- DELETE(sl);
+ delete sl;
user->Shrink("silence_list");
}
}