diff options
| author | Adam <Adam@drink-coca-cola.info> | 2010-04-29 17:31:34 -0400 |
|---|---|---|
| committer | Adam <Adam@anope.org> | 2010-06-18 20:58:52 -0400 |
| commit | c1d161dec451ea790ff87078b5d80b1f71a3e9f0 (patch) | |
| tree | 2ada0230d0411d10bb1e710d701874d253a4d4aa /src/protocol/inspircd11.c | |
| parent | 73e93305c10f349742fad3b2197c6c5dd3aea34e (diff) | |
Rewrote all of the server handling code
Diffstat (limited to 'src/protocol/inspircd11.c')
| -rw-r--r-- | src/protocol/inspircd11.c | 13 |
1 files changed, 5 insertions, 8 deletions
diff --git a/src/protocol/inspircd11.c b/src/protocol/inspircd11.c index b5c55cfa8..764b887de 100644 --- a/src/protocol/inspircd11.c +++ b/src/protocol/inspircd11.c @@ -204,7 +204,7 @@ class InspIRCdProto : public IRCDProto /* SERVER services-dev.chatspike.net password 0 :Description here */ void SendServer(Server *server) { - send_cmd(Config.ServerName, "SERVER %s %s %d :%s", server->name, currentpass, server->hops, server->desc); + send_cmd(Config.ServerName, "SERVER %s %s %d :%s", server->GetName().c_str(), currentpass, server->GetHops(), server->GetDescription().c_str()); } /* JOIN */ @@ -248,9 +248,9 @@ class InspIRCdProto : public IRCDProto void SendConnect() { + Me = new Server(NULL, Config.ServerName, 0, Config.ServerDesc, ""); inspircd_cmd_pass(uplink_server->password); - me_server = new_server(NULL, Config.ServerName, Config.ServerDesc, SERVER_ISME, ""); - SendServer(me_server); + SendServer(Me); send_cmd(NULL, "BURST"); send_cmd(Config.ServerName, "VERSION :Anope-%s %s :%s - %s (%s) -- %s", version_number, Config.ServerName, ircd->name, version_flags, Config.EncModuleList.begin()->c_str(), version_build); } @@ -823,10 +823,7 @@ int anope_event_chghost(const char *source, int ac, const char **av) /* EVENT: SERVER */ int anope_event_server(const char *source, int ac, const char **av) { - if (!stricmp(av[1], "1")) { - uplink = sstrdup(av[0]); - } - do_server(source, av[0], av[1], av[2], ""); + do_server(source, av[0], atoi(av[1]), av[2], ""); return MOD_CONT; } @@ -1100,7 +1097,7 @@ int anope_event_capab(const char *source, int ac, const char **av) int anope_event_endburst(const char *source, int ac, const char **av) { - finish_sync(serv_uplink, 1); + Me->GetUplink()->Sync(true); return MOD_CONT; } |
