summaryrefslogtreecommitdiff
path: root/src/protocol/ratbox.c
diff options
context:
space:
mode:
authorRobin Burchell w00t@inspircd.org <Robin Burchell w00t@inspircd.org@5417fbe8-f217-4b02-8779-1006273d7864>2008-09-30 18:45:11 +0000
committerRobin Burchell w00t@inspircd.org <Robin Burchell w00t@inspircd.org@5417fbe8-f217-4b02-8779-1006273d7864>2008-09-30 18:45:11 +0000
commit58ab9f234cdabbf1a181fcd4d090a7b7b98836cc (patch)
treeafa29b4847f1c67c11ece155e6469c533b1bcbee /src/protocol/ratbox.c
parent6e0bee3ab1cd085f7ef572c7762ea9425e6dd418 (diff)
Added cmd_message() function to IRCDProtoNew class. (Replaces cmd_notice)
git-svn-id: http://anope.svn.sourceforge.net/svnroot/anope/trunk@1227 5417fbe8-f217-4b02-8779-1006273d7864
Diffstat (limited to 'src/protocol/ratbox.c')
-rw-r--r--src/protocol/ratbox.c26
1 files changed, 8 insertions, 18 deletions
diff --git a/src/protocol/ratbox.c b/src/protocol/ratbox.c
index 42cb65f84..beba9aade 100644
--- a/src/protocol/ratbox.c
+++ b/src/protocol/ratbox.c
@@ -440,24 +440,15 @@ CUMode myCumodes[128] = {
-void ratbox_cmd_notice(const char *source, const char *dest, const char *buf)
+void RatboxProto::cmd_message(const char *source, const char *dest, const char *buf)
{
- Uid *ud;
- User *u;
-
- if (!buf) {
- return;
- }
-
- if (NSDefFlags & NI_MSG) {
- ircd_proto.cmd_privmsg(source, dest, buf);
- } else {
- ud = find_uid(source);
- u = finduser(dest);
- send_cmd((UseTS6 ? (ud ? ud->uid : source) : source),
- "NOTICE %s :%s", (UseTS6 ? (u ? u->uid : dest) : dest),
- buf);
- }
+ if (!buf) return;
+ if (NSDefFlags & NI_MSG) cmd_privmsg(source, dest, buf);
+ else {
+ Uid *ud = find_uid(source);
+ User *u = finduser(dest);
+ send_cmd(UseTS6 ? (ud ? ud->uid : source) : source, "NOTICE %s :%s", UseTS6 ? (u ? u->uid : dest) : dest, buf);
+ }
}
void ratbox_cmd_notice2(const char *source, const char *dest, const char *msg)
@@ -1662,7 +1653,6 @@ void moduleAddAnopeCmds()
pmodule_cmd_372_error(ratbox_cmd_372_error);
pmodule_cmd_375(ratbox_cmd_375);
pmodule_cmd_376(ratbox_cmd_376);
- pmodule_cmd_notice(ratbox_cmd_notice);
pmodule_cmd_notice2(ratbox_cmd_notice2);
pmodule_cmd_serv_notice(ratbox_cmd_serv_notice);
pmodule_cmd_serv_privmsg(ratbox_cmd_serv_privmsg);