X-Git-Url: https://git.netwichtig.de/gitweb/?a=blobdiff_plain;f=src%2Fmodules%2Fm_devoice.cpp;h=214de57833a21d967ccb241c92b8636e75850fc4;hb=3a7023f2c595d14778b3f1f7e53d3914698dd500;hp=70d510b9ae493a3a17436cbf912029e9abde0176;hpb=b0cb12952a378d4d3717d3a5556325a15be1de0a;p=user%2Fhenk%2Fcode%2Finspircd.git diff --git a/src/modules/m_devoice.cpp b/src/modules/m_devoice.cpp index 70d510b9a..214de5783 100644 --- a/src/modules/m_devoice.cpp +++ b/src/modules/m_devoice.cpp @@ -2,7 +2,7 @@ * | Inspire Internet Relay Chat Daemon | * +------------------------------------+ * - * Inspire is copyright (C) 2002-2004 ChatSpike-Dev. + * InspIRCd is copyright (C) 2002-2006 ChatSpike-Dev. * E-mail: * * @@ -28,17 +28,17 @@ using namespace std; #include "channels.h" #include "modules.h" -Server *Srv; +static Server *Srv; class cmd_devoice : public command_t { public: - cmd_devoice () : command_t("DEVOICE", 'o', 2) + cmd_devoice () : command_t("DEVOICE", 0, 1) { this->source = "m_devoice.so"; } - void Handle (char **parameters, int pcnt, userrec *user) + void Handle (const char** parameters, int pcnt, userrec *user) { /* * NOTE: DO NOT CODE LIKE THIS!!! This has no checks and can send @@ -46,12 +46,12 @@ class cmd_devoice : public command_t * * - I'm not aware what checking I need, so for now... be supreme evil. */ - char* modes[3]; - modes[0] = parameters[0]; - modes[1] = "-v"; - modes[2] = user->nick; + const char* modes[3]; + modes[0] = parameters[0]; + modes[1] = "-v"; + modes[2] = user->nick; - Srv->SendMode(modes,3,user); + Srv->SendMode(modes,3,user); } }; @@ -96,7 +96,7 @@ class ModuleDeVoiceFactory : public ModuleFactory }; -extern "C" void * init_module( void ) +extern "C" void * module_init( void ) { return new ModuleDeVoiceFactory; }