| OLD | NEW |
| 1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 #include "net/proxy/proxy_config_service_win.h" | 5 #include "net/proxy/proxy_config_service_win.h" |
| 6 | 6 |
| 7 #include <windows.h> | 7 #include <windows.h> |
| 8 #include <winhttp.h> | 8 #include <winhttp.h> |
| 9 | 9 |
| 10 #include "base/logging.h" | 10 #include "base/logging.h" |
| (...skipping 161 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 172 if (ie_config.fAutoDetect) | 172 if (ie_config.fAutoDetect) |
| 173 config->set_auto_detect(true); | 173 config->set_auto_detect(true); |
| 174 if (ie_config.lpszProxy) { | 174 if (ie_config.lpszProxy) { |
| 175 // lpszProxy may be a single proxy, or a proxy per scheme. The format | 175 // lpszProxy may be a single proxy, or a proxy per scheme. The format |
| 176 // is compatible with ProxyConfig::ProxyRules's string format. | 176 // is compatible with ProxyConfig::ProxyRules's string format. |
| 177 config->proxy_rules().ParseFromString(WideToASCII(ie_config.lpszProxy)); | 177 config->proxy_rules().ParseFromString(WideToASCII(ie_config.lpszProxy)); |
| 178 } | 178 } |
| 179 if (ie_config.lpszProxyBypass) { | 179 if (ie_config.lpszProxyBypass) { |
| 180 std::string proxy_bypass = WideToASCII(ie_config.lpszProxyBypass); | 180 std::string proxy_bypass = WideToASCII(ie_config.lpszProxyBypass); |
| 181 | 181 |
| 182 StringTokenizer proxy_server_bypass_list(proxy_bypass, "; \t\n\r"); | 182 StringTokenizer proxy_server_bypass_list(proxy_bypass, ";, \t\n\r"); |
| 183 while (proxy_server_bypass_list.GetNext()) { | 183 while (proxy_server_bypass_list.GetNext()) { |
| 184 std::string bypass_url_domain = proxy_server_bypass_list.token(); | 184 std::string bypass_url_domain = proxy_server_bypass_list.token(); |
| 185 config->proxy_rules().bypass_rules.AddRuleFromString(bypass_url_domain); | 185 config->proxy_rules().bypass_rules.AddRuleFromString(bypass_url_domain); |
| 186 } | 186 } |
| 187 } | 187 } |
| 188 if (ie_config.lpszAutoConfigUrl) | 188 if (ie_config.lpszAutoConfigUrl) |
| 189 config->set_pac_url(GURL(ie_config.lpszAutoConfigUrl)); | 189 config->set_pac_url(GURL(ie_config.lpszAutoConfigUrl)); |
| 190 } | 190 } |
| 191 | 191 |
| 192 } // namespace net | 192 } // namespace net |
| OLD | NEW |