cloud inspecting ...

This commit is contained in:
2024-03-15 19:49:37 +03:00
parent 2b738f6f43
commit 3fa5d9d9df
5 changed files with 29 additions and 15 deletions

View File

@@ -54,9 +54,8 @@ void CloudServer::removeClient(DispatcherClient * c) {
PIVector<DispatcherClient *> CloudServer::getClients() {
mutex_clients.lock();
PIMutexLocker locker(mutex_clients);
PIVector<DispatcherClient *> cl = clients;
mutex_clients.unlock();
return cl;
}
@@ -67,11 +66,10 @@ double CloudServer::lastPing() {
void CloudServer::printStatus() {
mutex_clients.lock();
PIMutexLocker locker(mutex_clients);
piCout << " "
<< "Clients for" << server->address() << server_uuid.toHex() << ":";
for (auto c: clients) {
piCout << " " << c->address() << c->clientId();
}
mutex_clients.unlock();
}