Fixed lua crash caused by lion with optimizations

This commit is contained in:
Anonymous275
2021-02-23 00:29:15 +02:00
committed by Anonymous275
parent f52308c439
commit 9b1bf071a8
11 changed files with 29 additions and 29 deletions

View File

@@ -29,7 +29,7 @@ void TPPSMonitor::operator()() {
Application::SetPPS("-");
continue;
}
mServer.ForEachClient([&](std::weak_ptr<TClient> ClientPtr) -> bool {
mServer.ForEachClient([&](const std::weak_ptr<TClient>& ClientPtr) -> bool {
if (!ClientPtr.expired()) {
auto c = ClientPtr.lock();
if (c->GetCarCount() > 0) {