diff options
author | cyberbotx <cyberbotx@5417fbe8-f217-4b02-8779-1006273d7864> | 2009-02-15 01:00:20 +0000 |
---|---|---|
committer | cyberbotx <cyberbotx@5417fbe8-f217-4b02-8779-1006273d7864> | 2009-02-15 01:00:20 +0000 |
commit | 2c9f2eb991467197762d39b6a7eaf688c55520b3 (patch) | |
tree | 860cfc08574d3bfc64029347ebd7d81633218762 /src/modules/hs_request.c | |
parent | 0717d63c75496d328ae19ff9482230a63d8fe624 (diff) |
Audited all src/modules/* and deleted bs_fantasy_unban (it was obsoleted).
git-svn-id: http://anope.svn.sourceforge.net/svnroot/anope/trunk@2051 5417fbe8-f217-4b02-8779-1006273d7864
Diffstat (limited to 'src/modules/hs_request.c')
-rw-r--r-- | src/modules/hs_request.c | 11 |
1 files changed, 7 insertions, 4 deletions
diff --git a/src/modules/hs_request.c b/src/modules/hs_request.c index ab9044737..a57e09282 100644 --- a/src/modules/hs_request.c +++ b/src/modules/hs_request.c @@ -82,7 +82,7 @@ class CommandHSRequest : public Command CommandReturn Execute(User *u, std::vector<std::string> ¶ms) { char *nick; - const char *rawhostmask = params[1].c_str(); + const char *rawhostmask = params[0].c_str(); char hostmask[HOSTMAX]; NickAlias *na; int32 tmp_time; @@ -359,7 +359,7 @@ class HSListBase : public Command return MOD_CONT; } public: - HSListBase(const std::string &cmd, int min, int max) : Command("LIST", 1, 1) + HSListBase(const std::string &cmd, int min, int max) : Command(cmd, min, max) { } @@ -372,13 +372,16 @@ class HSListBase : public Command class CommandHSList : public HSListBase { public: - CommandHSList() : HSListBase("LIST", 1, 1) + CommandHSList() : HSListBase("LIST", 0, 1) { } CommandReturn Execute(User *u, std::vector<std::string> ¶ms) { - const char *key = params[0].c_str(); + const char *key = params.size() ? params[0].c_str() : NULL; + + if (!key) + return MOD_CONT; if (stricmp(key, "+req")) return MOD_CONT; |