1
0
mirror of https://github.com/anope/anope.git synced 2026-06-25 03:26:38 +02:00

Change the return type of ircdmessage to void now that we don't use it, add an ircd message module event, and a few more fixups

This commit is contained in:
Adam
2012-11-23 16:56:06 -05:00
parent 0e7bd9f3ba
commit 36b1166cf6
17 changed files with 227 additions and 345 deletions
+6 -11
View File
@@ -156,7 +156,7 @@ struct IRCDMessageEncap : IRCDMessage
{
IRCDMessageEncap(Module *creator) : IRCDMessage(creator, "ENCAP", 4) { SetFlag(IRCDMESSAGE_REQUIRE_SERVER); }
bool Run(MessageSource &source, const std::vector<Anope::string> &params) anope_override
void Run(MessageSource &source, const std::vector<Anope::string> &params) anope_override
{
/*
* Received: :dev.anope.de ENCAP * SU DukePyrolator DukePyrolator
@@ -194,7 +194,7 @@ struct IRCDMessageEncap : IRCDMessage
FOREACH_MOD(I_OnFingerprint, OnFingerprint(u));
}
}
return true;
return;
}
};
@@ -202,10 +202,9 @@ struct IRCDMessagePass : IRCDMessage
{
IRCDMessagePass(Module *creator) : IRCDMessage(creator, "PASS", 4) { SetFlag(IRCDMESSAGE_REQUIRE_SERVER); }
bool Run(MessageSource &source, const std::vector<Anope::string> &params) anope_override
void Run(MessageSource &source, const std::vector<Anope::string> &params) anope_override
{
UplinkSID = params[3];
return true;
}
};
@@ -215,15 +214,13 @@ struct IRCDMessageServer : IRCDMessage
/* 0 1 2 */
/* SERVER hades.arpa 1 :ircd-hybrid test server */
bool Run(MessageSource &source, const std::vector<Anope::string> &params) anope_override
void Run(MessageSource &source, const std::vector<Anope::string> &params) anope_override
{
/* Servers other than our immediate uplink are introduced via SID */
if (params[1] != "1")
return true;
return;
new Server(source.GetServer() == NULL ? Me : source.GetServer(), params[0], 1, params[2], UplinkSID);
return true;
}
};
@@ -245,7 +242,7 @@ struct IRCDMessageUID : IRCDMessage
params[10] = info
*/
// :42X UID Adam 1 1348535644 +aow Adam 192.168.0.5 192.168.0.5 42XAAAAAB 0 192.168.0.5 :Adam
bool Run(MessageSource &source, const std::vector<Anope::string> &params) anope_override
void Run(MessageSource &source, const std::vector<Anope::string> &params) anope_override
{
/* An IP of 0 means the user is spoofed */
Anope::string ip = params[6];
@@ -261,8 +258,6 @@ struct IRCDMessageUID : IRCDMessage
}
else if (user && user->server->IsSynced() && NickServService)
NickServService->Validate(user);
return true;
}
};