From eed00fd454dd33bf47f9d605ecbdd9b610e14e7e Mon Sep 17 00:00:00 2001 From: danieldg Date: Wed, 22 Apr 2009 16:35:27 +0000 Subject: Addendum to previous ping patch: NextPingTime was not being set at endburst, and servers without ENDBURST were no longer being detected. git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@11325 e03df62e-2008-0410-955e-edbf42e46eb7 --- src/modules/m_spanningtree/treeserver.cpp | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/src/modules/m_spanningtree/treeserver.cpp b/src/modules/m_spanningtree/treeserver.cpp index ff16b6d60..bffcf0576 100644 --- a/src/modules/m_spanningtree/treeserver.cpp +++ b/src/modules/m_spanningtree/treeserver.cpp @@ -53,7 +53,8 @@ TreeServer::TreeServer(SpanningTreeUtilities* Util, InspIRCd* Instance, std::str bursting = true; VersionString.clear(); ServerUserCount = ServerOperCount = 0; - this->SetNextPingTime(ServerInstance->Time() + Utils->PingFreq); + SetNextPingTime(ServerInstance->Time() + Utils->PingFreq); + SetPingFlag(); Warned = false; rtt = 0; @@ -127,6 +128,8 @@ std::string& TreeServer::GetID() void TreeServer::FinishBurstInternal() { this->bursting = false; + SetNextPingTime(ServerInstance->Time() + Utils->PingFreq); + SetPingFlag(); for(unsigned int q=0; q < ChildCount(); q++) { TreeServer* child = GetChild(q); @@ -144,7 +147,6 @@ void TreeServer::FinishBurst() unsigned long bursttime = ts - this->StartBurst; ServerInstance->SNO->WriteToSnoMask('l', "Received end of netburst from \2%s\2 (burst time: %lu %s)", ServerName.c_str(), (bursttime > 10000 ? bursttime / 1000 : bursttime), (bursttime > 10000 ? "secs" : "msecs")); - SetPingFlag(); Event rmode((char*)ServerName.c_str(), (Module*)Utils->Creator, "new_server"); rmode.Send(ServerInstance); } -- cgit v1.2.3