From af6decf96c6da276b8f7da080e26bbad903a3a72 Mon Sep 17 00:00:00 2001 From: John Date: Sat, 12 Mar 2022 13:00:38 +0100 Subject: [PATCH] fix potential illegal access --- src/ebusd/network.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/ebusd/network.cpp b/src/ebusd/network.cpp index 125fcd64..da4e1e23 100644 --- a/src/ebusd/network.cpp +++ b/src/ebusd/network.cpp @@ -329,9 +329,9 @@ void Network::run() { continue; } Connection* connection = new Connection(socket, isHttp, m_netQueue); + string ip = socket->getIP(); connection->start("connection"); m_connections.push_back(connection); - string ip = socket->getIP(); logInfo(lf_network, "[%05d] %s connection opened %s", connection->getID(), isHttp ? "HTTP" : "client", ip.c_str()); }