summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorShane Kearns <ext-shane.2.kearns@nokia.com>2012-02-22 20:20:27 +0000
committerQt by Nokia <qt-info@nokia.com>2012-03-08 05:31:40 +0100
commit25c05ce3bb8b53ed937363492b8222ee3b83d749 (patch)
tree71b7df4c9042f47afc206c4ba0f45df53b1860f0 /src
parenta7489b2ba3f2f3ea28d6fff0c835c12b0666af45 (diff)
Windows - handle proxy autoconfiguration resulting in no proxy
The PAC file may result in direct connection, in which case WinHttp returns null strings for the proxies and the connection type marked as direct. In this case, return the default list (no proxy) Change-Id: I601033f56a841bb92ea80a28174bb993b024ad79 Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
Diffstat (limited to 'src')
-rw-r--r--src/network/kernel/qnetworkproxy_win.cpp2
1 files changed, 2 insertions, 0 deletions
diff --git a/src/network/kernel/qnetworkproxy_win.cpp b/src/network/kernel/qnetworkproxy_win.cpp
index 37c0cc4838..324f3cccf5 100644
--- a/src/network/kernel/qnetworkproxy_win.cpp
+++ b/src/network/kernel/qnetworkproxy_win.cpp
@@ -417,6 +417,8 @@ QList<QNetworkProxy> QNetworkProxyFactory::systemProxyForQuery(const QNetworkPro
if (proxyInfo.lpszProxyBypass)
GlobalFree(proxyInfo.lpszProxyBypass);
+ if (proxyInfo.dwAccessType == WINHTTP_ACCESS_TYPE_NO_PROXY)
+ return sp->defaultResult; //i.e. the PAC file result was "DIRECT"
if (isBypassed(query.peerHostName(), splitSpaceSemicolon(proxyBypass)))
return sp->defaultResult;
return parseServerList(query, proxyServerList);