summaryrefslogtreecommitdiffstats
path: root/net/proxy/proxy_service.cc
diff options
context:
space:
mode:
Diffstat (limited to 'net/proxy/proxy_service.cc')
-rw-r--r--net/proxy/proxy_service.cc13
1 files changed, 13 insertions, 0 deletions
diff --git a/net/proxy/proxy_service.cc b/net/proxy/proxy_service.cc
index 1c6c4059..c684979 100644
--- a/net/proxy/proxy_service.cc
+++ b/net/proxy/proxy_service.cc
@@ -29,12 +29,15 @@
#include "net/proxy/proxy_service.h"
+#if defined(OS_WIN)
#include <windows.h>
#include <winhttp.h>
+#endif
#include <algorithm>
#include "base/message_loop.h"
+#include "base/notimplemented.h"
#include "base/string_tokenizer.h"
#include "base/string_util.h"
#include "googleurl/src/gurl.h"
@@ -165,6 +168,7 @@ void ProxyInfo::UseNamedProxy(const std::string& proxy_server) {
proxy_list_.Set(proxy_server);
}
+#if defined(OS_WIN)
void ProxyInfo::Apply(HINTERNET request_handle) {
WINHTTP_PROXY_INFO pi;
std::wstring proxy; // We need to declare this variable here because
@@ -182,6 +186,7 @@ void ProxyInfo::Apply(HINTERNET request_handle) {
}
WinHttpSetOption(request_handle, WINHTTP_OPTION_PROXY, &pi, sizeof(pi));
}
+#endif
// ProxyService::PacRequest ---------------------------------------------------
@@ -441,6 +446,14 @@ void ProxyService::DidCompletePacRequest(int config_id, int result_code) {
}
void ProxyService::UpdateConfig() {
+#if !defined(WIN_OS)
+ if (!resolver_) {
+ // Tied to the NOTIMPLEMENTED in HttpNetworkLayer::HttpNetworkLayer()
+ NOTIMPLEMENTED();
+ return;
+ }
+#endif
+
ProxyConfig latest;
if (resolver_->GetProxyConfig(&latest) != OK)
return;