+/* +------------------------------------+
+ * | Inspire Internet Relay Chat Daemon |
+ * +------------------------------------+
+ *
+ * InspIRCd: (C) 2002-2007 InspIRCd Development Team
+ * See: http://www.inspircd.org/wiki/index.php/Credits
+ *
+ * This program is free but copyrighted software; see
+ * the file COPYING for details.
+ *
+ * ---------------------------------------------------
+ */
+
#include "configreader.h"
#include "users.h"
#include "channels.h"
#include "m_spanningtree/utils.h"
#include "m_spanningtree/treeserver.h"
+/* $ModDep: m_spanningtree/utils.h m_spanningtree/treeserver.h */
+
TreeServer::TreeServer(SpanningTreeUtilities* Util, InspIRCd* Instance) : ServerInstance(Instance), Utils(Util)
{
Parent = NULL;
ServerDesc = "";
VersionString = "";
UserCount = OperCount = 0;
+ rtt = LastPing = 0;
+ Hidden = false;
VersionString = ServerInstance->GetVersionString();
}
VersionString = ServerInstance->GetVersionString();
Route = NULL;
Socket = NULL; /* Fix by brain */
+ rtt = LastPing = 0;
+ Hidden = false;
AddHashEntry();
}
* This constructor initializes the server's Route and Parent, and sets up
* its ping counters so that it will be pinged one minute from now.
*/
-TreeServer::TreeServer(SpanningTreeUtilities* Util, InspIRCd* Instance, std::string Name, std::string Desc, TreeServer* Above, TreeSocket* Sock)
- : ServerInstance(Instance), Parent(Above), ServerName(Name.c_str()), ServerDesc(Desc), Socket(Sock), Utils(Util)
+TreeServer::TreeServer(SpanningTreeUtilities* Util, InspIRCd* Instance, std::string Name, std::string Desc, TreeServer* Above, TreeSocket* Sock, bool Hide)
+ : ServerInstance(Instance), Parent(Above), ServerName(Name.c_str()), ServerDesc(Desc), Socket(Sock), Utils(Util), Hidden(Hide)
{
VersionString = "";
UserCount = OperCount = 0;
this->SetNextPingTime(time(NULL) + 60);
this->SetPingFlag();
+ rtt = LastPing = 0;
/* find the 'route' for this server (e.g. the one directly connected
* to the local server, which we can use to reach it)
*
{
userrec* a = (userrec*)*n;
if (!IS_LOCAL(a))
- userrec::QuitUser(ServerInstance,a,reason_s);
+ {
+ if (ServerInstance->Config->HideSplits)
+ userrec::QuitUser(ServerInstance, a, "*.net *.split", reason_s);
+ else
+ userrec::QuitUser(ServerInstance, a, reason_s);
+
+ if (this->Utils->quiet_bursts)
+ ServerInstance->GlobalCulls.MakeSilent(a);
+ }
}
return time_to_die.size();
}