P2PServer: truncate too long peers list in api

This commit is contained in:
SChernykh 2023-03-27 12:15:33 +02:00
parent 3697c079fa
commit 5c67f0df20

View file

@ -1260,6 +1260,11 @@ void P2PServer::api_update_local_stats()
<< client->m_broadcastMaxHeight << ','
<< static_cast<char*>(client->m_addrString)
<< '"';
if (s.m_pos + 128 >= s.m_bufSize) {
break;
}
first = false;
}
}