diff options
Diffstat (limited to 'src/network/kernel/qnetworkinterface_win.cpp')
-rw-r--r-- | src/network/kernel/qnetworkinterface_win.cpp | 15 |
1 files changed, 5 insertions, 10 deletions
diff --git a/src/network/kernel/qnetworkinterface_win.cpp b/src/network/kernel/qnetworkinterface_win.cpp index a8f5213..1d700c3 100644 --- a/src/network/kernel/qnetworkinterface_win.cpp +++ b/src/network/kernel/qnetworkinterface_win.cpp @@ -66,19 +66,14 @@ static void resolveLibs() if (!done) { done = true; - HINSTANCE iphlpapiHnd; - QT_WA({ - iphlpapiHnd = LoadLibraryW(L"iphlpapi"); - }, { - iphlpapiHnd = LoadLibraryA("iphlpapi"); - }); + HINSTANCE iphlpapiHnd = LoadLibrary(L"iphlpapi"); if (iphlpapiHnd == NULL) - return; // failed to load, probably Windows 95 + return; #if defined(Q_OS_WINCE) - ptrGetAdaptersInfo = (PtrGetAdaptersInfo)GetProcAddressW(iphlpapiHnd, L"GetAdaptersInfo"); - ptrGetAdaptersAddresses = (PtrGetAdaptersAddresses)GetProcAddressW(iphlpapiHnd, L"GetAdaptersAddresses"); - ptrGetNetworkParams = (PtrGetNetworkParams)GetProcAddressW(iphlpapiHnd, L"GetNetworkParams"); + ptrGetAdaptersInfo = (PtrGetAdaptersInfo)GetProcAddress(iphlpapiHnd, L"GetAdaptersInfo"); + ptrGetAdaptersAddresses = (PtrGetAdaptersAddresses)GetProcAddress(iphlpapiHnd, L"GetAdaptersAddresses"); + ptrGetNetworkParams = (PtrGetNetworkParams)GetProcAddress(iphlpapiHnd, L"GetNetworkParams"); #else ptrGetAdaptersInfo = (PtrGetAdaptersInfo)GetProcAddress(iphlpapiHnd, "GetAdaptersInfo"); ptrGetAdaptersAddresses = (PtrGetAdaptersAddresses)GetProcAddress(iphlpapiHnd, "GetAdaptersAddresses"); |