diff options
author | Robin Burchell w00t@inspircd.org <Robin Burchell w00t@inspircd.org@5417fbe8-f217-4b02-8779-1006273d7864> | 2008-09-30 18:45:11 +0000 |
---|---|---|
committer | Robin Burchell w00t@inspircd.org <Robin Burchell w00t@inspircd.org@5417fbe8-f217-4b02-8779-1006273d7864> | 2008-09-30 18:45:11 +0000 |
commit | a3d2bc65e2ea2327966257d6170f46b0f7f611f3 (patch) | |
tree | dd08d9cb3c15db68f32dc3663a4f6721aa0bdebf | |
parent | c4d520b465f8aa7f5924b17b697fa760b6ead409 (diff) |
Added cmd_serv_privmsg() function to IRCDProtoNew class.
git-svn-id: http://anope.svn.sourceforge.net/svnroot/anope/trunk@1233 5417fbe8-f217-4b02-8779-1006273d7864
-rw-r--r-- | include/extern.h | 1 | ||||
-rw-r--r-- | include/services.h | 5 | ||||
-rw-r--r-- | src/ircd.c | 9 | ||||
-rw-r--r-- | src/protocol/bahamut.c | 6 | ||||
-rw-r--r-- | src/protocol/bahamut.h | 1 | ||||
-rw-r--r-- | src/protocol/charybdis.c | 7 | ||||
-rw-r--r-- | src/protocol/charybdis.h | 1 | ||||
-rw-r--r-- | src/protocol/inspircd11.c | 8 | ||||
-rwxr-xr-x | src/protocol/inspircd11.h | 1 | ||||
-rw-r--r-- | src/protocol/ratbox.c | 7 | ||||
-rw-r--r-- | src/protocol/ratbox.h | 1 | ||||
-rw-r--r-- | src/protocol/unreal32.c | 6 | ||||
-rw-r--r-- | src/protocol/unreal32.h | 1 |
13 files changed, 5 insertions, 49 deletions
diff --git a/include/extern.h b/include/extern.h index 54e9134e8..6e56befe4 100644 --- a/include/extern.h +++ b/include/extern.h @@ -610,7 +610,6 @@ E void pmodule_cmd_372(void (*func) (const char *source, const char *msg)); E void pmodule_cmd_372_error(void (*func) (const char *source)); E void pmodule_cmd_375(void (*func) (const char *source)); E void pmodule_cmd_376(void (*func) (const char *source)); -E void pmodule_cmd_serv_privmsg(void (*func) (const char *source, const char *dest, const char *msg)); E void pmodule_cmd_bot_chan_mode(void (*func) (const char *nick, const char *chan)); E void pmodule_cmd_351(void (*func) (const char *source)); E void pmodule_cmd_quit(void (*func) (const char *source, const char *buf)); diff --git a/include/services.h b/include/services.h index 8e3ee7611..c60d6cbd0 100644 --- a/include/services.h +++ b/include/services.h @@ -1060,7 +1060,6 @@ typedef struct ircd_proto_ { void (*ircd_cmd_372_error)(const char *source); void (*ircd_cmd_375)(const char *source); void (*ircd_cmd_376)(const char *source); - void (*ircd_cmd_serv_privmsg)(const char *source, const char *dest, const char *msg); void (*ircd_cmd_bot_chan_mode)(const char *nick, const char *chan); void (*ircd_cmd_351)(const char *source); void (*ircd_cmd_quit)(const char *source, const char *buf); @@ -1323,6 +1322,10 @@ class IRCDProtoNew { { send_cmd(source, "NOTICE %s%s :%s", ircd->globaltldprefix, dest, msg); } + virtual void cmd_serv_privmsg(const char *source, const char *dest, const char *msg) + { + send_cmd(source, "PRIVMSG %s%s :%s", ircd->globaltldprefix, dest, msg); + } }; /*************************************************************************/ diff --git a/src/ircd.c b/src/ircd.c index ad09ccf73..e4523d94b 100644 --- a/src/ircd.c +++ b/src/ircd.c @@ -50,7 +50,6 @@ void initIrcdProto() ircdproto.ircd_cmd_372_error = NULL; ircdproto.ircd_cmd_375 = NULL; ircdproto.ircd_cmd_376 = NULL; - ircdproto.ircd_cmd_serv_privmsg = NULL; ircdproto.ircd_cmd_bot_chan_mode = NULL; ircdproto.ircd_cmd_351 = NULL; ircdproto.ircd_cmd_quit = NULL; @@ -282,7 +281,7 @@ void anope_cmd_serv_notice(const char *source, const char *dest, const char *msg void anope_cmd_serv_privmsg(const char *source, const char *dest, const char *msg) { - ircdproto.ircd_cmd_serv_privmsg(source, dest, msg); + ircdprotonew->cmd_serv_privmsg(source, dest, msg); } void anope_cmd_bot_chan_mode(const char *nick, const char *chan) @@ -660,12 +659,6 @@ void pmodule_cmd_376(void (*func) (const char *source)) ircdproto.ircd_cmd_376 = func; } -void pmodule_cmd_serv_privmsg(void (*func) - (const char *source, const char *dest, const char *msg)) -{ - ircdproto.ircd_cmd_serv_privmsg = func; -} - void pmodule_cmd_bot_chan_mode(void (*func) (const char *nick, const char *chan)) { ircdproto.ircd_cmd_bot_chan_mode = func; diff --git a/src/protocol/bahamut.c b/src/protocol/bahamut.c index 3e56d1ce0..35eb9fc42 100644 --- a/src/protocol/bahamut.c +++ b/src/protocol/bahamut.c @@ -1028,11 +1028,6 @@ void BahamutIRCdProto::cmd_notice_ops(const char *source, const char *dest, cons send_cmd(NULL, "NOTICE @%s :%s", dest, buf); } -void bahamut_cmd_serv_privmsg(const char *source, const char *dest, const char *msg) -{ - send_cmd(source, "PRIVMSG $%s :%s", dest, msg); -} - /* GLOBOPS */ void bahamut_cmd_global(const char *source, const char *buf) { @@ -1493,7 +1488,6 @@ void moduleAddAnopeCmds() pmodule_cmd_372_error(bahamut_cmd_372_error); pmodule_cmd_375(bahamut_cmd_375); pmodule_cmd_376(bahamut_cmd_376); - pmodule_cmd_serv_privmsg(bahamut_cmd_serv_privmsg); pmodule_cmd_bot_chan_mode(bahamut_cmd_bot_chan_mode); pmodule_cmd_351(bahamut_cmd_351); pmodule_cmd_quit(bahamut_cmd_quit); diff --git a/src/protocol/bahamut.h b/src/protocol/bahamut.h index ae58dec96..99ad68600 100644 --- a/src/protocol/bahamut.h +++ b/src/protocol/bahamut.h @@ -63,7 +63,6 @@ void bahamut_cmd_372(const char *source, const char *msg); void bahamut_cmd_372_error(const char *source); void bahamut_cmd_375(const char *source); void bahamut_cmd_376(const char *source); -void bahamut_cmd_serv_privmsg(const char *source, const char *dest, const char *msg); void bahamut_cmd_bot_chan_mode(const char *nick, const char *chan); void bahamut_cmd_351(const char *source); void bahamut_cmd_quit(const char *source, const char *buf); diff --git a/src/protocol/charybdis.c b/src/protocol/charybdis.c index 3ae00d60d..a509aacea 100644 --- a/src/protocol/charybdis.c +++ b/src/protocol/charybdis.c @@ -473,12 +473,6 @@ void CharybdisProto::cmd_privmsg(const char *source, const char *dest, const cha send_cmd(UseTS6 ? (ud ? ud->uid : source) : source, "PRIVMSG %s :%s", UseTS6 ? (ud2 ? ud2->uid : dest) : dest, buf); } -void charybdis_cmd_serv_privmsg(const char *source, const char *dest, const char *msg) -{ - send_cmd(source, "PRIVMSG $$%s :%s", dest, msg); -} - - void charybdis_cmd_global(const char *source, const char *buf) { Uid *u; @@ -1747,7 +1741,6 @@ void moduleAddAnopeCmds() pmodule_cmd_372_error(charybdis_cmd_372_error); pmodule_cmd_375(charybdis_cmd_375); pmodule_cmd_376(charybdis_cmd_376); - pmodule_cmd_serv_privmsg(charybdis_cmd_serv_privmsg); pmodule_cmd_bot_chan_mode(charybdis_cmd_bot_chan_mode); pmodule_cmd_351(charybdis_cmd_351); pmodule_cmd_quit(charybdis_cmd_quit); diff --git a/src/protocol/charybdis.h b/src/protocol/charybdis.h index 9b370d8ee..fb88eb98d 100644 --- a/src/protocol/charybdis.h +++ b/src/protocol/charybdis.h @@ -51,7 +51,6 @@ void charybdis_cmd_372(const char *source, const char *msg); void charybdis_cmd_372_error(const char *source); void charybdis_cmd_375(const char *source); void charybdis_cmd_376(const char *source); -void charybdis_cmd_serv_privmsg(const char *source, const char *dest, const char *msg); void charybdis_cmd_bot_chan_mode(const char *nick, const char *chan); void charybdis_cmd_351(const char *source); void charybdis_cmd_quit(const char *source, const char *buf); diff --git a/src/protocol/inspircd11.c b/src/protocol/inspircd11.c index 60a32f9ef..a8347d457 100644 --- a/src/protocol/inspircd11.c +++ b/src/protocol/inspircd11.c @@ -780,13 +780,6 @@ void InspIRCdProto::cmd_notice_ops(const char *source, const char *dest, const c send_cmd(ServerName, "NOTICE @%s :%s", dest, buf); } - -void inspircd_cmd_serv_privmsg(const char *source, const char *dest, const char *msg) -{ - send_cmd(source, "PRIVMSG $%s :%s", dest, msg); -} - - void inspircd_cmd_bot_chan_mode(const char *nick, const char *chan) { anope_cmd_mode(nick, chan, "%s %s %s", ircd->botchanumode, nick, nick); @@ -1741,7 +1734,6 @@ void moduleAddAnopeCmds() pmodule_cmd_372_error(inspircd_cmd_372_error); pmodule_cmd_375(inspircd_cmd_375); pmodule_cmd_376(inspircd_cmd_376); - pmodule_cmd_serv_privmsg(inspircd_cmd_serv_privmsg); pmodule_cmd_bot_chan_mode(inspircd_cmd_bot_chan_mode); pmodule_cmd_351(inspircd_cmd_351); pmodule_cmd_quit(inspircd_cmd_quit); diff --git a/src/protocol/inspircd11.h b/src/protocol/inspircd11.h index c333d5059..6343bb711 100755 --- a/src/protocol/inspircd11.h +++ b/src/protocol/inspircd11.h @@ -56,7 +56,6 @@ void inspircd_cmd_372(const char *source, const char *msg); void inspircd_cmd_372_error(const char *source); void inspircd_cmd_375(const char *source); void inspircd_cmd_376(const char *source); -void inspircd_cmd_serv_privmsg(const char *source, const char *dest, const char *msg); void inspircd_cmd_bot_chan_mode(const char *nick, const char *chan); void inspircd_cmd_351(const char *source); void inspircd_cmd_quit(const char *source, const char *buf); diff --git a/src/protocol/ratbox.c b/src/protocol/ratbox.c index eed5e4e70..f5d9dcfe1 100644 --- a/src/protocol/ratbox.c +++ b/src/protocol/ratbox.c @@ -462,12 +462,6 @@ void RatboxProto::cmd_privmsg(const char *source, const char *dest, const char * send_cmd(UseTS6 ? (ud ? ud->uid : source) : source, "PRIVMSG %s :%s", UseTS6 ? (ud2 ? ud2->uid : dest) : dest, buf); } -void ratbox_cmd_serv_privmsg(const char *source, const char *dest, const char *msg) -{ - send_cmd(source, "PRIVMSG $$%s :%s", dest, msg); -} - - void ratbox_cmd_global(const char *source, const char *buf) { Uid *u; @@ -1641,7 +1635,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_serv_privmsg(ratbox_cmd_serv_privmsg); pmodule_cmd_bot_chan_mode(ratbox_cmd_bot_chan_mode); pmodule_cmd_351(ratbox_cmd_351); pmodule_cmd_quit(ratbox_cmd_quit); diff --git a/src/protocol/ratbox.h b/src/protocol/ratbox.h index 8f3d56321..21f205184 100644 --- a/src/protocol/ratbox.h +++ b/src/protocol/ratbox.h @@ -50,7 +50,6 @@ void ratbox_cmd_372(const char *source, const char *msg); void ratbox_cmd_372_error(const char *source); void ratbox_cmd_375(const char *source); void ratbox_cmd_376(const char *source); -void ratbox_cmd_serv_privmsg(const char *source, const char *dest, const char *msg); void ratbox_cmd_bot_chan_mode(const char *nick, const char *chan); void ratbox_cmd_351(const char *source); void ratbox_cmd_quit(const char *source, const char *buf); diff --git a/src/protocol/unreal32.c b/src/protocol/unreal32.c index 103e7ead5..8879aea15 100644 --- a/src/protocol/unreal32.c +++ b/src/protocol/unreal32.c @@ -630,11 +630,6 @@ void UnrealIRCdProto::cmd_notice_ops(const char *source, const char *dest, const } -void unreal_cmd_serv_privmsg(const char *source, const char *dest, const char *msg) -{ - send_cmd(source, "%s $%s :%s", send_token("PRIVMSG", "!"), dest, msg); -} - void unreal_cmd_bot_chan_mode(const char *nick, const char *chan) { anope_cmd_mode(nick, chan, "%s %s %s", myIrcd->botchanumode, nick, @@ -2041,7 +2036,6 @@ void moduleAddAnopeCmds() pmodule_cmd_372_error(unreal_cmd_372_error); pmodule_cmd_375(unreal_cmd_375); pmodule_cmd_376(unreal_cmd_376); - pmodule_cmd_serv_privmsg(unreal_cmd_serv_privmsg); pmodule_cmd_bot_chan_mode(unreal_cmd_bot_chan_mode); pmodule_cmd_351(unreal_cmd_351); pmodule_cmd_quit(unreal_cmd_quit); diff --git a/src/protocol/unreal32.h b/src/protocol/unreal32.h index 3561d9c70..0770da420 100644 --- a/src/protocol/unreal32.h +++ b/src/protocol/unreal32.h @@ -85,7 +85,6 @@ void unreal_cmd_372(const char *source, const char *msg); void unreal_cmd_372_error(const char *source); void unreal_cmd_375(const char *source); void unreal_cmd_376(const char *source); -void unreal_cmd_serv_privmsg(const char *source, const char *dest, const char *msg); void unreal_cmd_bot_chan_mode(const char *nick, const char *chan); void unreal_cmd_351(const char *source); void unreal_cmd_quit(const char *source, const char *buf); |