]> git.netwichtig.de Git - user/henk/code/inspircd.git/blobdiff - src/modules/m_check.cpp
This needs some general QA-ing. Add support to new parser (introduced in 1.1) for...
[user/henk/code/inspircd.git] / src / modules / m_check.cpp
index a7d2485eeb771702834493c95cadf732042348e2..5304347c2d0375eb160fcace2bd8584adcb6f204 100644 (file)
@@ -62,6 +62,7 @@ class cmd_check : public command_t
                        user->WriteServ(checkstr + " realnuh " + targuser->GetFullRealHost());
                        user->WriteServ(checkstr + " realname " + targuser->fullname);
                        user->WriteServ(checkstr + " modes +" + targuser->FormatModes());
+                       user->WriteServ(checkstr + " snomasks +" + targuser->FormatNoticeMasks());
                        user->WriteServ(checkstr + " server " + targuser->server);
                        if (targuser->awaymsg[0] != 0)
                        {
@@ -71,7 +72,7 @@ class cmd_check : public command_t
                        if (targuser->oper[0] != 0)
                        {
                                /* user is an oper of type ____ */
-                               user->WriteServ(checkstr + " opertype " + targuser->oper);
+                               user->WriteServ(checkstr + " opertype " + irc::Spacify(targuser->oper));
                        }
                        if (IS_LOCAL(targuser))
                        {
@@ -128,7 +129,7 @@ class cmd_check : public command_t
                        long x = 0;
 
                        /* hostname or other */
-                       for (user_hash::const_iterator a = ServerInstance->clientlist.begin(); a != ServerInstance->clientlist.end(); a++)
+                       for (user_hash::const_iterator a = ServerInstance->clientlist->begin(); a != ServerInstance->clientlist->end(); a++)
                        {
                                if (match(a->second->host, parameters[0]) || match(a->second->dhost, parameters[0]))
                                {
@@ -136,7 +137,7 @@ class cmd_check : public command_t
                                        user->WriteServ(checkstr + " match " + ConvToStr(++x) + " " + a->second->GetFullRealHost());
                                }
                                /* IP address */
-                               else if (match(a->second->GetIPString(), parameters[0]))
+                               else if (match(a->second->GetIPString(), parameters[0], true))
                                {
                                        /* same IP. */
                                        user->WriteServ(checkstr + " match " + ConvToStr(++x) + " " + a->second->GetFullRealHost());
@@ -148,7 +149,7 @@ class cmd_check : public command_t
 
                user->WriteServ(checkstr + " END " + std::string(parameters[0]));
 
-               return CMD_SUCCESS;
+               return CMD_LOCALONLY;
        }
 };