diff --git a/tests/auto/network/kernel/qnetworkinterface/tst_qnetworkinterface.cpp b/tests/auto/network/kernel/qnetworkinterface/tst_qnetworkinterface.cpp index 5695f90c531..e9034deff76 100644 --- a/tests/auto/network/kernel/qnetworkinterface/tst_qnetworkinterface.cpp +++ b/tests/auto/network/kernel/qnetworkinterface/tst_qnetworkinterface.cpp @@ -32,7 +32,7 @@ #include #include -#include +#include #ifndef QT_NO_BEARERMANAGEMENT #include #include @@ -189,17 +189,12 @@ void tst_QNetworkInterface::loopbackIPv6() void tst_QNetworkInterface::localAddress() { - QTcpSocket socket; + QUdpSocket socket; socket.connectToHost(QtNetworkSettings::serverName(), 80); QVERIFY(socket.waitForConnected(5000)); QHostAddress local = socket.localAddress(); - // make Apache happy on fluke - socket.write("GET / HTTP/1.0\r\n\r\n"); - socket.waitForBytesWritten(1000); - socket.close(); - // test that we can find the address that QTcpSocket reported QList all = QNetworkInterface::allAddresses(); QVERIFY(all.contains(local));