diff options
author | Joerg Bornemann <joerg.bornemann@nokia.com> | 2010-02-26 15:19:54 (GMT) |
---|---|---|
committer | Joerg Bornemann <joerg.bornemann@nokia.com> | 2010-02-26 15:19:54 (GMT) |
commit | ed1d9f24d035857438e5bb9ccb423310bc30310b (patch) | |
tree | ef949d57470b11331a6a2b667f2cdb5467c285cd /src/plugins/bearer | |
parent | ab9a87eb2a5af0b74834e247f44fb4fad0dfb8cb (diff) | |
parent | 27e403d9c6185c606980bb7881e39a2c88138a13 (diff) | |
download | Qt-ed1d9f24d035857438e5bb9ccb423310bc30310b.zip Qt-ed1d9f24d035857438e5bb9ccb423310bc30310b.tar.gz Qt-ed1d9f24d035857438e5bb9ccb423310bc30310b.tar.bz2 |
Merge remote branch 'origin/master' into berlin-master
Conflicts:
configure.exe
Diffstat (limited to 'src/plugins/bearer')
-rw-r--r-- | src/plugins/bearer/generic/qgenericengine.cpp | 12 | ||||
-rw-r--r-- | src/plugins/bearer/symbian/symbian.pro | 1 |
2 files changed, 6 insertions, 7 deletions
diff --git a/src/plugins/bearer/generic/qgenericengine.cpp b/src/plugins/bearer/generic/qgenericengine.cpp index f654038..e6c871d 100644 --- a/src/plugins/bearer/generic/qgenericengine.cpp +++ b/src/plugins/bearer/generic/qgenericengine.cpp @@ -60,6 +60,7 @@ #include <sys/ioctl.h> #include <net/if.h> #include <net/if_arp.h> +#include <unistd.h> #endif QT_BEGIN_NAMESPACE @@ -126,14 +127,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 \ |