1
0
mirror of https://github.com/anope/anope.git synced 2026-06-28 02:36:38 +02:00
git-svn-id: http://anope.svn.sourceforge.net/svnroot/anope/trunk@1990 5417fbe8-f217-4b02-8779-1006273d7864
This commit is contained in:
rburchell
2009-02-10 21:46:57 +00:00
parent 7d58ed17c7
commit 2e08b60cf7
2 changed files with 5 additions and 4 deletions
+2 -1
View File
@@ -24,7 +24,7 @@ class CommandOSOper : public Command
private:
CommandReturn DoAdd(User *u, std::vector<std::string> &params)
{
const char *nick = param.size() > 1 ? params[1].c_str() : NULL;
const char *nick = params.size() > 1 ? params[1].c_str() : NULL;
NickAlias *na;
int res = 0;
@@ -156,6 +156,7 @@ class CommandOSOper : public Command
{
int sent_header = 0;
const char *nick = params.size() > 1 ? params[1].c_str() : NULL;
int res = 0;
if (!is_oper(u))
{
+3 -3
View File
@@ -14,6 +14,7 @@
/*************************************************************************/
#include "module.h"
#include "hashcomp.h"
class CommandOSRaw : public Command
{
@@ -30,7 +31,7 @@ class CommandOSRaw : public Command
{
std::string kw;
spacesepstream textsep(text);
while (textsep.GetString(kw) && kw[0] == ':');
while (textsep.GetToken(kw) && kw[0] == ':');
ircdproto->SendGlobops(s_OperServ, "\2%s\2 used RAW command for \2%s\2", u->nick, !kw.empty() ? kw.c_str() : "\2non RFC compliant message\2");
}
alog("%s used RAW command for %s", u->nick, text);
@@ -63,8 +64,7 @@ class OSRaw : public Module
this->SetVersion("$Id$");
this->SetType(THIRD);
c = createCommand("RAW", do_raw, is_services_root, OPER_HELP_RAW, -1, -1, -1, -1);
this->AddCommand(OPERSERV, c, MOD_UNIQUE);
this->AddCommand(OPERSERV, new CommandOSRaw(), MOD_UNIQUE);
if (DisableRaw)
throw ModuleException("os_raw: Not loading because you probably shouldn't be loading me");