diff options
-rw-r--r-- | src/plugins/bearer/generic/qgenericengine.cpp | 11 | ||||
-rw-r--r-- | src/plugins/bearer/symbian/symbian.pro | 1 | ||||
-rw-r--r-- | tests/auto/qscriptvalue/qscriptvalue.pro | 7 |
3 files changed, 12 insertions, 7 deletions
diff --git a/src/plugins/bearer/generic/qgenericengine.cpp b/src/plugins/bearer/generic/qgenericengine.cpp index e96b80c..dc89342 100644 --- a/src/plugins/bearer/generic/qgenericengine.cpp +++ b/src/plugins/bearer/generic/qgenericengine.cpp @@ -126,14 +126,11 @@ static QString qGetInterfaceType(const QString &interface) ifreq request; strncpy(request.ifr_name, interface.toLocal8Bit().data(), sizeof(request.ifr_name)); - if (ioctl(sock, SIOCGIFHWADDR, &request) >= 0) { - switch (request.ifr_hwaddr.sa_family) { - case ARPHRD_ETHER: - return QLatin1String("Ethernet"); - } - } - + int result = ioctl(sock, SIOCGIFHWADDR, &request); close(sock); + + if (result >= 0 && request.ifr_hwaddr.sa_family == ARPHRD_ETHER) + return QLatin1String("Ethernet"); #else Q_UNUSED(interface); #endif diff --git a/src/plugins/bearer/symbian/symbian.pro b/src/plugins/bearer/symbian/symbian.pro index 9fd1a74..9613def 100644 --- a/src/plugins/bearer/symbian/symbian.pro +++ b/src/plugins/bearer/symbian/symbian.pro @@ -21,6 +21,7 @@ exists($${EPOCROOT}epoc32/release/armv5/lib/cmmanager.lib) { } INCLUDEPATH += $$APP_LAYER_SYSTEMINCLUDE +symbian-abld:INCLUDEPATH += $$QT_BUILD_TREE/include/QtNetwork/private LIBS += -lcommdb \ -lapsettingshandlerui \ diff --git a/tests/auto/qscriptvalue/qscriptvalue.pro b/tests/auto/qscriptvalue/qscriptvalue.pro index 1588cc5..191cd4a 100644 --- a/tests/auto/qscriptvalue/qscriptvalue.pro +++ b/tests/auto/qscriptvalue/qscriptvalue.pro @@ -5,3 +5,10 @@ HEADERS += tst_qscriptvalue.h # Generated by testgen SOURCES += tst_qscriptvalue_generated.cpp + + +win32-msvc* { + # With -O2, MSVC takes up to 24 minutes to compile this test! + QMAKE_CXXFLAGS_RELEASE -= -O1 -O2 + QMAKE_CXXFLAGS_RELEASE += -Od +} |