Do not run ping on clients that are not yet connected

This commit is contained in:
Vitaliy Filippov
2021-03-21 01:37:23 +03:00
parent 7e6e1a5a82
commit 23225c5e62
+1 -1
View File
@@ -33,7 +33,7 @@ void osd_messenger_t::init()
for (auto cl_it = clients.begin(); cl_it != clients.end();)
{
auto cl = (cl_it++)->second;
if (!cl->osd_num)
if (!cl->osd_num || cl->peer_state != PEER_CONNECTED)
{
// Do not run keepalive on regular clients
continue;