]> git.netwichtig.de Git - user/henk/code/inspircd.git/blobdiff - src/modules/m_swhois.cpp
Make rehash work more than once per run, and fix some uninitialized values in connect...
[user/henk/code/inspircd.git] / src / modules / m_swhois.cpp
index 196b556dc4428d86fd3e6f743ae92cb71dadff3d..da8e1b6c4804fd75a1c8a26d0c731a5994841b50 100644 (file)
@@ -2,8 +2,8 @@
  *       | Inspire Internet Relay Chat Daemon |
  *       +------------------------------------+
  *
- *  InspIRCd: (C) 2002-2008 InspIRCd Development Team
- * See: http://www.inspircd.org/wiki/index.php/Credits
+ *  InspIRCd: (C) 2002-2009 InspIRCd Development Team
+ * See: http://wiki.inspircd.org/Credits
  *
  * This program is free but copyrighted software; see
  *            the file COPYING for details.
@@ -21,7 +21,7 @@ class CommandSwhois : public Command
 {
 
  public:
-       CommandSwhois (InspIRCd* Instance) : Command(Instance,"SWHOIS","o",2)
+       CommandSwhois (InspIRCd* Instance) : Command(Instance,"SWHOIS","o",2, 2)
        {
                this->source = "m_swhois.so";
                syntax = "<nick> :<swhois>";
@@ -44,7 +44,7 @@ class CommandSwhois : public Command
                        // We already had it set...
                        if (!ServerInstance->ULine(user->server))
                                // Ulines set SWHOISes silently
-                               ServerInstance->SNO->WriteToSnoMask('A', "%s used SWHOIS to set %s's extra whois from '%s' to '%s'", user->nick.c_str(), dest->nick.c_str(), text->c_str(), parameters[1].c_str());
+                               ServerInstance->SNO->WriteGlobalSno('a', "%s used SWHOIS to set %s's extra whois from '%s' to '%s'", user->nick.c_str(), dest->nick.c_str(), text->c_str(), parameters[1].c_str());
 
                        dest->Shrink("swhois");
                        delete text;
@@ -52,7 +52,7 @@ class CommandSwhois : public Command
                else if (!ServerInstance->ULine(user->server))
                {
                        // Ulines set SWHOISes silently
-                       ServerInstance->SNO->WriteToSnoMask('A', "%s used SWHOIS to set %s's extra whois to '%s'", user->nick.c_str(), dest->nick.c_str(), parameters[1].c_str());
+                       ServerInstance->SNO->WriteGlobalSno('a', "%s used SWHOIS to set %s's extra whois to '%s'", user->nick.c_str(), dest->nick.c_str(), parameters[1].c_str());
                }
 
                text = new std::string(parameters[1]);
@@ -95,7 +95,7 @@ class ModuleSWhois : public Module
                ServerInstance->Modules->Attach(eventlist, this, 7);
        }
 
-       void OnRehash(User* user, const std::string &parameter)
+       void OnRehash(User* user)
        {
                delete Conf;
                Conf = new ConfigReader(ServerInstance);
@@ -251,7 +251,7 @@ class ModuleSWhois : public Module
 
        virtual Version GetVersion()
        {
-               return Version(1, 2, 0, 0, VF_COMMON | VF_VENDOR, API_VERSION);
+               return Version("$Id$", VF_COMMON | VF_VENDOR, API_VERSION);
        }
 };