1
0
mirror of https://github.com/anope/anope.git synced 2026-07-08 09:03:13 +02:00

Rework the config file reader to be much more flexible and move many configuration directives to the actual modules they are used in.

This commit is contained in:
Adam
2013-05-05 01:55:04 -04:00
parent 781defb707
commit 1d0bb9b26b
165 changed files with 3093 additions and 4861 deletions
+5 -6
View File
@@ -53,7 +53,7 @@ class ngIRCdProto : public IRCDProto
void SendConnect() anope_override
{
UplinkSocket::Message() << "PASS " << Config->Uplinks[Anope::CurrentUplink]->password << " 0210-IRC+ Anope|" << Anope::VersionShort() << ":CLHMSo P";
UplinkSocket::Message() << "PASS " << Config->Uplinks[Anope::CurrentUplink].password << " 0210-IRC+ Anope|" << Anope::VersionShort() << ":CLHMSo P";
/* Make myself known to myself in the serverlist */
SendServer(Me);
/* finish the enhanced server handshake and register the connection */
@@ -184,11 +184,10 @@ struct IRCDMessage005 : IRCDMessage
}
else if (parameter == "NICKLEN")
{
unsigned newlen = convertTo<unsigned>(data);
if (Config->NickLen != newlen)
unsigned newlen = convertTo<unsigned>(data), len = Config->GetBlock("networkinfo")->Get<unsigned>("nicklen");
if (len != newlen)
{
Log() << "NickLen changed from " << Config->NickLen << " to " << newlen;
Config->NickLen = newlen;
Log() << "Warning: NICKLEN is " << newlen << " but networkinfo:nicklen is " << len;
}
}
}
@@ -540,7 +539,7 @@ struct IRCDMessageServer : IRCDMessage
* when receiving a new server and then finish sync once we
* get a pong back from that server.
*/
IRCD->SendPing(Config->ServerName, params[0]);
IRCD->SendPing(Me->GetName(), params[0]);
}
};