diff --git a/src/common/restapi/http/ServerConnectionManager.h b/src/common/restapi/http/ServerConnectionManager.h index fe4e2e9f..214db239 100644 --- a/src/common/restapi/http/ServerConnectionManager.h +++ b/src/common/restapi/http/ServerConnectionManager.h @@ -77,10 +77,10 @@ namespace restapi */ void stopAll() { + std::lock_guard guard(m_lock); for (auto c : m_connections) c->stop(); - std::lock_guard guard(m_lock); m_connections.clear(); }