Don't set ConnectDelay to zero

This commit is contained in:
Alexey Sokolov
2014-04-26 16:45:04 +01:00
parent a1800282c2
commit 0952ee82e0
2 changed files with 5 additions and 1 deletions
+1
View File
@@ -991,6 +991,7 @@ bool CIRCNetwork::Connect() {
return false;
if (CZNC::Get().GetServerThrottle(pServer->GetName())) {
// Can't connect right now, schedule retry later
CZNC::Get().AddNetworkToQueue(this);
return false;
}
+4 -1
View File
@@ -2009,6 +2009,10 @@ protected:
};
void CZNC::SetConnectDelay(unsigned int i) {
if (i < 1) {
// Don't hammer server with our failed connects
i = 1;
}
if (m_uiConnectDelay != i && m_pConnectQueueTimer != NULL) {
m_pConnectQueueTimer->Start(i);
}
@@ -2057,7 +2061,6 @@ void CZNC::AddNetworkToQueue(CIRCNetwork *pNetwork) {
}
}
m_lpConnectQueue.push_back(pNetwork);
EnableConnectQueue();
}