From d9558e35c323862df89956cd217ae7ead7f3d2e2 Mon Sep 17 00:00:00 2001 From: Simon Walton Date: Fri, 23 Aug 2019 13:19:31 -0700 Subject: [PATCH] Fix typo in last commit; remove useless call of getGuessedLocalAddress; logging tweak --- libraries/networking/src/udt/Socket.cpp | 4 ++-- libraries/shared/src/shared/FileLogger.cpp | 1 - libraries/shared/src/shared/NetworkUtils.cpp | 2 +- 3 files changed, 3 insertions(+), 4 deletions(-) diff --git a/libraries/networking/src/udt/Socket.cpp b/libraries/networking/src/udt/Socket.cpp index c25075171b..4c01517346 100644 --- a/libraries/networking/src/udt/Socket.cpp +++ b/libraries/networking/src/udt/Socket.cpp @@ -263,7 +263,7 @@ Connection* Socket::findOrCreateConnection(const HifiSockAddr& sockAddr, bool fi if (filterCreate && _connectionCreationFilterOperator && !_connectionCreationFilterOperator(sockAddr)) { // the connection creation filter did not allow us to create a new connection #ifdef UDT_CONNECTION_DEBUG - qCDebug(networking) << "Socket::findOrCreateConnection refusing to create connection for" << sockAddr + qCDebug(networking) << "Socket::findOrCreateConnection refusing to create Connection class for" << sockAddr << "due to connection creation filter"; #endif // UDT_CONNECTION_DEBUG return nullptr; @@ -279,7 +279,7 @@ Connection* Socket::findOrCreateConnection(const HifiSockAddr& sockAddr, bool fi QObject::connect(connection.get(), &Connection::receiverHandshakeRequestComplete, this, &Socket::clientHandshakeRequestComplete); - qCDebug(networking) << "Creating new connection to" << sockAddr; + qCDebug(networking) << "Creating new Connection class for" << sockAddr; it = _connectionsHash.insert(it, std::make_pair(sockAddr, std::move(connection))); } diff --git a/libraries/shared/src/shared/FileLogger.cpp b/libraries/shared/src/shared/FileLogger.cpp index b64d08c0d8..2ccc247af3 100644 --- a/libraries/shared/src/shared/FileLogger.cpp +++ b/libraries/shared/src/shared/FileLogger.cpp @@ -56,7 +56,6 @@ static FilePersistThread* _persistThreadInstance; QString getLogRollerFilename() { QString result = FileUtils::standardPath(LOGS_DIRECTORY); - QHostAddress clientAddress = getGuessedLocalAddress(); QDateTime now = QDateTime::currentDateTime(); QString fileSessionID; diff --git a/libraries/shared/src/shared/NetworkUtils.cpp b/libraries/shared/src/shared/NetworkUtils.cpp index 1bfbc8678a..705eac39c9 100644 --- a/libraries/shared/src/shared/NetworkUtils.cpp +++ b/libraries/shared/src/shared/NetworkUtils.cpp @@ -10,7 +10,7 @@ #include namespace { - const QString LINK_LOCAL_SUBNET {"169.154."}; + const QString LINK_LOCAL_SUBNET {"169.254."}; // Is address local-subnet valid only (rfc 3927): bool isLinkLocalAddress(const QHostAddress& ip4Addr) {