1
0
mirror of https://github.com/anope/anope.git synced 2026-07-09 01:43:12 +02:00

Added cmd_server() function to IRCDProtoNew class.

git-svn-id: http://anope.svn.sourceforge.net/svnroot/anope/trunk@1268 5417fbe8-f217-4b02-8779-1006273d7864
This commit is contained in:
Robin Burchell w00t@inspircd.org
2008-09-30 18:45:13 +00:00
parent ae4f3a615f
commit 7eb190b1bd
12 changed files with 27 additions and 27 deletions
-1
View File
@@ -1196,7 +1196,6 @@ E void anope_cmd_serv_privmsg(const char *source, const char *dest, const char *
E void anope_cmd_protoctl(); /* PROTOCTL */
E void anope_cmd_quit(const char *source, const char *fmt, ...); /* QUIT */
E void anope_cmd_remove_akill(const char *user, const char *host); /* RAKILL */
E void anope_cmd_server(const char *servname, int hop, const char *descript); /* SERVER */
E void anope_cmd_sgline(const char *mask, const char *reason); /* SGLINE */
E void anope_cmd_sqline(const char *mask, const char *reason); /* SQLINE */
E void anope_cmd_szline(const char *mask, const char *reason, const char *whom); /* SZLINE */
+1
View File
@@ -1364,6 +1364,7 @@ class IRCDProtoNew {
virtual void cmd_svspart(const char *, const char *, const char *) { }
virtual void cmd_swhois(const char *, const char *, const char *) { }
virtual void cmd_eob() { }
virtual void cmd_server(const char *, int, const char *) = 0;
};
/*************************************************************************/
+4 -4
View File
@@ -822,9 +822,9 @@ void bahamut_cmd_pass(const char *pass)
}
/* SERVER */
void bahamut_cmd_server(const char *servname, int hop, const char *descript)
void BahamutIRCdProto::cmd_server(const char *servname, int hop, const char *descript)
{
send_cmd(NULL, "SERVER %s %d :%s", servname, hop, descript);
send_cmd(NULL, "SERVER %s %d :%s", servname, hop, descript);
}
/* CAPAB */
@@ -841,7 +841,7 @@ void BahamutIRCdProto::cmd_connect()
else if (servernum == 2) bahamut_cmd_pass(RemotePassword2);
else if (servernum == 3) bahamut_cmd_pass(RemotePassword3);
bahamut_cmd_capab();
bahamut_cmd_server(ServerName, 1, ServerDesc);
cmd_server(ServerName, 1, ServerDesc);
bahamut_cmd_svinfo();
bahamut_cmd_burst();
}
@@ -1296,7 +1296,7 @@ void bahamut_cmd_jupe(const char *jserver, const char *who, const char *reason)
if (findserver(servlist, jserver))
ircd_proto.cmd_squit(jserver, rbuf);
bahamut_cmd_server(jserver, 2, rbuf);
ircd_proto.cmd_server(jserver, 2, rbuf);
new_server(me_server, jserver, rbuf, SERVER_JUPED, NULL);
}
+1
View File
@@ -111,4 +111,5 @@ class BahamutIRCdProto : public IRCDProtoNew {
void cmd_nc_change(User *);
void cmd_svid_umode3(User *, const char *);
void cmd_eob();
void cmd_server(const char *, int, const char *);
} ircd_proto;
+4 -4
View File
@@ -885,9 +885,9 @@ void charybdis_cmd_pass(const char *pass)
}
/* SERVER name hop descript */
void charybdis_cmd_server(const char *servname, int hop, const char *descript)
void CharybdisProto::cmd_server(const char *servname, int hop, const char *descript)
{
send_cmd(NULL, "SERVER %s %d :%s", servname, hop, descript);
send_cmd(NULL, "SERVER %s %d :%s", servname, hop, descript);
}
void CharybdisProto::cmd_connect()
@@ -899,7 +899,7 @@ void CharybdisProto::cmd_connect()
else if (servernum == 2) charybdis_cmd_pass(RemotePassword2);
else if (servernum == 3) charybdis_cmd_pass(RemotePassword3);
charybdis_cmd_capab();
charybdis_cmd_server(ServerName, 1, ServerDesc);
cmd_server(ServerName, 1, ServerDesc);
charybdis_cmd_svinfo();
}
@@ -1515,7 +1515,7 @@ void charybdis_cmd_jupe(const char *jserver, const char *who, const char *reason
if (findserver(servlist, jserver))
ircd_proto.cmd_squit(jserver, rbuf);
charybdis_cmd_server(jserver, 2, rbuf);
ircd_proto.cmd_server(jserver, 2, rbuf);
new_server(me_server, jserver, rbuf, SERVER_JUPED, NULL);
}
+1
View File
@@ -100,4 +100,5 @@ class CharybdisProto : public IRCDProtoNew {
void cmd_release_svshold(const char *);
void cmd_unsgline(const char *);
void cmd_sgline(const char *, const char *);
void cmd_server(const char *, int, const char *);
} ircd_proto;
+4 -5
View File
@@ -806,10 +806,9 @@ void inspircd_cmd_pass(const char *pass)
}
/* SERVER services-dev.chatspike.net password 0 :Description here */
void inspircd_cmd_server(const char *servname, int hop, const char *descript)
void InspIRCdProto::cmd_server(const char *servname, int hop, const char *descript)
{
send_cmd(ServerName, "SERVER %s %s %d :%s", servname, currentpass, hop,
descript);
send_cmd(ServerName, "SERVER %s %s %d :%s", servname, currentpass, hop, descript);
}
/* JOIN */
@@ -989,7 +988,7 @@ void InspIRCdProto::cmd_connect()
if (servernum == 1) inspircd_cmd_pass(RemotePassword);
else if (servernum == 2) inspircd_cmd_pass(RemotePassword2);
else if (servernum == 3) inspircd_cmd_pass(RemotePassword3);
inspircd_cmd_server(ServerName, 0, ServerDesc);
cmd_server(ServerName, 0, ServerDesc);
send_cmd(NULL, "BURST");
send_cmd(ServerName, "VERSION :Anope-%s %s :%s - %s (%s) -- %s", version_number, ServerName, ircd->name, version_flags, EncModule, version_build);
me_server = new_server(NULL, ServerName, ServerDesc, SERVER_ISME, NULL);
@@ -1546,7 +1545,7 @@ void inspircd_cmd_jupe(const char *jserver, const char *who, const char *reason)
if (findserver(servlist, jserver))
ircd_proto.cmd_squit(jserver, rbuf);
inspircd_cmd_server(jserver, 1, rbuf);
ircd_proto.cmd_server(jserver, 1, rbuf);
new_server(me_server, jserver, rbuf, SERVER_JUPED, NULL);
}
+1
View File
@@ -114,4 +114,5 @@ class InspIRCdProto : public IRCDProtoNew {
void cmd_svsjoin(const char *, const char *, const char *, const char *);
void cmd_svspart(const char *, const char *, const char *);
void cmd_eob();
void cmd_server(const char *, int, const char *);
} ircd_proto;
+4 -4
View File
@@ -820,9 +820,9 @@ void ratbox_cmd_pass(const char *pass)
}
/* SERVER name hop descript */
void ratbox_cmd_server(const char *servname, int hop, const char *descript)
void RatboxProto::cmd_server(const char *servname, int hop, const char *descript)
{
send_cmd(NULL, "SERVER %s %d :%s", servname, hop, descript);
send_cmd(NULL, "SERVER %s %d :%s", servname, hop, descript);
}
void RatboxProto::cmd_connect()
@@ -834,7 +834,7 @@ void RatboxProto::cmd_connect()
else if (servernum == 2) ratbox_cmd_pass(RemotePassword2);
else if (servernum == 3) ratbox_cmd_pass(RemotePassword3);
ratbox_cmd_capab();
ratbox_cmd_server(ServerName, 1, ServerDesc);
cmd_server(ServerName, 1, ServerDesc);
ratbox_cmd_svinfo();
}
@@ -1410,7 +1410,7 @@ void ratbox_cmd_jupe(const char *jserver, const char *who, const char *reason)
if (findserver(servlist, jserver))
ircd_proto.cmd_squit(jserver, rbuf);
ratbox_cmd_server(jserver, 2, rbuf);
ircd_proto.cmd_server(jserver, 2, rbuf);
new_server(me_server, jserver, rbuf, SERVER_JUPED, NULL);
}
+1
View File
@@ -95,4 +95,5 @@ class RatboxProto : public IRCDProtoNew {
void cmd_connect();
void cmd_unsgline(const char *);
void cmd_sgline(const char *, const char *);
void cmd_server(const char *, int, const char *);
} ircd_proto;
+5 -9
View File
@@ -686,14 +686,10 @@ void unreal_cmd_pass(const char *pass)
/* SERVER name hop descript */
/* Unreal 3.2 actually sends some info about itself in the descript area */
void unreal_cmd_server(const char *servname, int hop, const char *descript)
void UnrealIRCdProto::cmd_server(const char *servname, int hop, const char *descript)
{
if (Numeric) {
send_cmd(NULL, "SERVER %s %d :U0-*-%s %s", servname, hop, Numeric,
descript);
} else {
send_cmd(NULL, "SERVER %s %d :%s", servname, hop, descript);
}
if (Numeric) send_cmd(NULL, "SERVER %s %d :U0-*-%s %s", servname, hop, Numeric, descript);
else send_cmd(NULL, "SERVER %s %d :%s", servname, hop, descript);
}
/* JOIN */
@@ -907,7 +903,7 @@ void UnrealIRCdProto::cmd_connect()
if (servernum == 1) unreal_cmd_pass(RemotePassword);
else if (servernum == 2) unreal_cmd_pass(RemotePassword2);
else if (servernum == 3) unreal_cmd_pass(RemotePassword3);
unreal_cmd_server(ServerName, 1, ServerDesc);
cmd_server(ServerName, 1, ServerDesc);
}
/* Events */
@@ -1593,7 +1589,7 @@ void unreal_cmd_jupe(const char *jserver, const char *who, const char *reason)
if (findserver(servlist, jserver))
ircd_proto.cmd_squit(jserver, rbuf);
unreal_cmd_server(jserver, 2, rbuf);
ircd_proto.cmd_server(jserver, 2, rbuf);
new_server(me_server, jserver, rbuf, SERVER_JUPED, NULL);
}
+1
View File
@@ -140,4 +140,5 @@ class UnrealIRCdProto : public IRCDProtoNew {
void cmd_svspart(const char *, const char *, const char *);
void cmd_swhois(const char *, const char *, const char *);
void cmd_eob();
void cmd_server(const char *, int, const char *);
} ircd_proto;