summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--src/modules/m_spanningtree/main.cpp4
-rw-r--r--src/modules/m_spanningtree/treesocket1.cpp2
2 files changed, 4 insertions, 2 deletions
diff --git a/src/modules/m_spanningtree/main.cpp b/src/modules/m_spanningtree/main.cpp
index e744b675a..3e5e2beb9 100644
--- a/src/modules/m_spanningtree/main.cpp
+++ b/src/modules/m_spanningtree/main.cpp
@@ -147,6 +147,7 @@ void ModuleSpanningTree::DoPingChecks(time_t curtime)
*/
long ts = ServerInstance->Time() * 1000 + (ServerInstance->Time_ns() / 1000000);
+restart:
for (server_hash::iterator i = Utils->serverlist.begin(); i != Utils->serverlist.end(); i++)
{
TreeServer *s = i->second;
@@ -156,6 +157,7 @@ void ModuleSpanningTree::DoPingChecks(time_t curtime)
s->GetSocket()->SendError("Ping timeout");
s->GetSocket()->Squit(s,"Ping timeout");
s->GetSocket()->Close();
+ goto restart;
}
// Fix for bug #792, do not ping servers that are not connected yet!
@@ -196,7 +198,7 @@ void ModuleSpanningTree::DoPingChecks(time_t curtime)
sock->SendError("Ping timeout");
sock->Squit(s,"Ping timeout");
sock->Close();
- return;
+ goto restart;
}
}
}
diff --git a/src/modules/m_spanningtree/treesocket1.cpp b/src/modules/m_spanningtree/treesocket1.cpp
index ea87c615f..5efa58f3b 100644
--- a/src/modules/m_spanningtree/treesocket1.cpp
+++ b/src/modules/m_spanningtree/treesocket1.cpp
@@ -137,7 +137,7 @@ void TreeSocket::OnError(BufferedSocketError e)
{
ServerInstance->SNO->WriteGlobalSno('l', "Connection to \002%s\002 failed with error: %s",
myhost.c_str(), getError().c_str());
- ServerInstance->GlobalCulls.AddItem(this);
+ LinkState = DYING;
}
void TreeSocket::SendError(const std::string &errormessage)