mirror of
https://github.com/znc/znc.git
synced 2026-08-08 01:43:03 +02:00
Added a server ping for idle connections - Thanks zparta
git-svn-id: https://znc.svn.sourceforge.net/svnroot/znc/trunk@732 726aef4b-f618-498e-8847-2d620e286838
This commit is contained in:
@@ -40,6 +40,11 @@ private:
|
||||
protected:
|
||||
virtual void RunJob() {
|
||||
vector<CClient*>& vClients = m_pUser->GetClients();
|
||||
CIRCSock* pIRCSock = m_pUser->GetIRCSock();
|
||||
|
||||
if (pIRCSock && pIRCSock->GetTimeSinceLastWrite() >= 270) {
|
||||
pIRCSock->PutIRC("PING :ZNC");
|
||||
}
|
||||
|
||||
for (size_t a = 0; a < vClients.size(); a++) {
|
||||
CClient* pClient = vClients[a];
|
||||
|
||||
Reference in New Issue
Block a user