]> git.netwichtig.de Git - user/henk/code/inspircd.git/commitdiff
Addendum to previous ping patch: NextPingTime was not being set at endburst, and...
authordanieldg <danieldg@e03df62e-2008-0410-955e-edbf42e46eb7>
Wed, 22 Apr 2009 16:35:27 +0000 (16:35 +0000)
committerdanieldg <danieldg@e03df62e-2008-0410-955e-edbf42e46eb7>
Wed, 22 Apr 2009 16:35:27 +0000 (16:35 +0000)
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@11325 e03df62e-2008-0410-955e-edbf42e46eb7

src/modules/m_spanningtree/treeserver.cpp

index ff16b6d60f67df56d1d8c2cc2e903eeae423c854..bffcf0576385af8a2564e38fbd693095e3f81e81 100644 (file)
@@ -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);
 }