diff options
author | Nodir Temirkhodjaev <[email protected]> | 2025-03-25 13:07:32 +0500 |
---|---|---|
committer | Volker Hilsheimer <[email protected]> | 2025-03-25 14:43:36 +0000 |
commit | 23a4b586f7137a86028e731dbaf800b1ebcf738a (patch) | |
tree | 53e0c3219b8264dd18b3f74cf4e24a6d1bbe0f0d | |
parent | 76bc2dd3905435fbe72edcc8adce0435cddffca2 (diff) |
qnetworkinterface.cpp: Rename "interface" variables to "iface" to fix a unity build
On Windows the "interface" is defined as "struct".
Pick-to: 6.9 6.8
Task-number: QTBUG-122980
Change-Id: I1a80c9e40d59449bb3c3773679a95405ea39d630
Reviewed-by: Volker Hilsheimer <[email protected]>
-rw-r--r-- | src/network/kernel/qnetworkinterface.cpp | 20 |
1 files changed, 10 insertions, 10 deletions
diff --git a/src/network/kernel/qnetworkinterface.cpp b/src/network/kernel/qnetworkinterface.cpp index fea6d4451b9..f2d5ccf0960 100644 --- a/src/network/kernel/qnetworkinterface.cpp +++ b/src/network/kernel/qnetworkinterface.cpp @@ -29,8 +29,8 @@ static QList<QNetworkInterfacePrivate *> postProcess(QList<QNetworkInterfacePriv // The math is: // broadcast = IP | ~netmask - for (QNetworkInterfacePrivate *interface : list) { - for (QNetworkAddressEntry &address : interface->addressEntries) { + for (QNetworkInterfacePrivate *iface : list) { + for (QNetworkAddressEntry &address : iface->addressEntries) { if (address.ip().protocol() != QAbstractSocket::IPv4Protocol) continue; @@ -62,11 +62,11 @@ QSharedDataPointer<QNetworkInterfacePrivate> QNetworkInterfaceManager::interface bool ok; uint index = name.toUInt(&ok); - for (const auto &interface : interfaceList) { - if (ok && interface->index == int(index)) - return interface; - else if (interface->name == name) - return interface; + for (const auto &iface : interfaceList) { + if (ok && iface->index == int(index)) + return iface; + else if (iface->name == name) + return iface; } return empty; @@ -75,9 +75,9 @@ QSharedDataPointer<QNetworkInterfacePrivate> QNetworkInterfaceManager::interface QSharedDataPointer<QNetworkInterfacePrivate> QNetworkInterfaceManager::interfaceFromIndex(int index) { const auto interfaceList = allInterfaces(); - for (const auto &interface : interfaceList) { - if (interface->index == index) - return interface; + for (const auto &iface : interfaceList) { + if (iface->index == index) + return iface; } return empty; |