]> git.netwichtig.de Git - user/henk/code/inspircd.git/blobdiff - src/modules/m_dccallow.cpp
m_spanningtree Replace WriteLine() call with Unicast() in DoCollision()
[user/henk/code/inspircd.git] / src / modules / m_dccallow.cpp
index e5c8df6aa9ab8f2bba0e3fd519ed5818e2e80c4b..cc7fbd323020b50757b466de89d11a66526324da 100644 (file)
@@ -62,7 +62,7 @@ class CommandDccallow : public Command
                : Command(parent, "DCCALLOW", 0)
                , ext(Ext)
        {
-               syntax = "{[+|-]<nick> <time>|HELP|LIST}";
+               syntax = "[(+|-)<nick> [<time>]]|[LIST|HELP]";
                /* XXX we need to fix this so it can work with translation stuff (i.e. move +- into a seperate param */
        }
 
@@ -168,7 +168,7 @@ class CommandDccallow : public Command
                                                length = InspIRCd::Duration(parameters[1]);
                                        }
 
-                                       if (!ServerInstance->IsValidMask(mask))
+                                       if (!InspIRCd::IsValidMask(mask))
                                        {
                                                return CMD_FAILURE;
                                        }
@@ -205,7 +205,7 @@ class CommandDccallow : public Command
 
        void DisplayHelp(User* user)
        {
-               user->WriteNumeric(998, ":DCCALLOW [<+|->nick [time]] [list] [help]");
+               user->WriteNumeric(998, ":DCCALLOW [(+|-)<nick> [<time>]]|[LIST|HELP]");
                user->WriteNumeric(998, ":You may allow DCCs from specific users by specifying a");
                user->WriteNumeric(998, ":DCC allow for the user you want to receive DCCs from.");
                user->WriteNumeric(998, ":For example, to allow the user Brain to send you inspircd.exe");
@@ -225,6 +225,10 @@ class CommandDccallow : public Command
                user->WriteNumeric(998, ":  they will be removed from your DCCALLOW list.");
                user->WriteNumeric(998, ":  your DCCALLOW list will be deleted when you leave IRC.");
                user->WriteNumeric(999, ":End of DCCALLOW HELP");
+
+               LocalUser* localuser = IS_LOCAL(user);
+               if (localuser)
+                       localuser->CommandFloodPenalty += 4000;
        }
 
        void DisplayDCCAllowList(User* user)