From 51fff29dc2dae1a8be5ea107d2b13205510c4e46 Mon Sep 17 00:00:00 2001 From: "ericroman@google.com" Date: Fri, 19 Dec 2008 22:17:53 +0000 Subject: Split ProxyResolver into two interfaces: A. interface for retrieving the system proxy settings (ProxyConfigService) B. interface for resolving the proxy (ProxyResolver)The motivation behind this change is: 1. Simplify sharing the WinHTTP code that fetches IE settings, with the V8 proxy resolver (avoids having platform-specific code in ProxyResolverV8). 2. Restrict objects to one thread. (ProxyService calls the config getter on IO thread, and the proxy resolving on the PAC thread).(ProxyResolver is now only 1 method, but this will grow shortly). Review URL: http://codereview.chromium.org/15070 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@7323 0039d316-1c4b-4281-b951-d872f2087c98 --- net/url_request/url_request_unittest.cc | 3 +-- net/url_request/url_request_unittest.h | 3 +-- 2 files changed, 2 insertions(+), 4 deletions(-) (limited to 'net/url_request') diff --git a/net/url_request/url_request_unittest.cc b/net/url_request/url_request_unittest.cc index d344319..be26da9 100644 --- a/net/url_request/url_request_unittest.cc +++ b/net/url_request/url_request_unittest.cc @@ -29,7 +29,6 @@ #include "net/disk_cache/disk_cache.h" #include "net/http/http_cache.h" #include "net/http/http_network_layer.h" -#include "net/proxy/proxy_resolver_null.h" #include "net/proxy/proxy_service.h" #include "net/url_request/url_request.h" #include "testing/gtest/include/gtest/gtest.h" @@ -42,7 +41,7 @@ namespace { class URLRequestHttpCacheContext : public URLRequestContext { public: URLRequestHttpCacheContext() { - proxy_service_ = new net::ProxyService(new net::ProxyResolverNull); + proxy_service_ = net::ProxyService::CreateNull(); http_transaction_factory_ = new net::HttpCache(net::HttpNetworkLayer::CreateFactory(proxy_service_), disk_cache::CreateInMemoryCacheBackend(0)); diff --git a/net/url_request/url_request_unittest.h b/net/url_request/url_request_unittest.h index 52fa429..a33be39 100644 --- a/net/url_request/url_request_unittest.h +++ b/net/url_request/url_request_unittest.h @@ -23,7 +23,6 @@ #include "net/base/net_errors.h" #include "net/http/http_network_layer.h" #include "net/url_request/url_request.h" -#include "net/proxy/proxy_resolver_null.h" #include "net/proxy/proxy_service.h" #include "testing/gtest/include/gtest/gtest.h" #include "googleurl/src/url_util.h" @@ -35,7 +34,7 @@ const std::string kDefaultHostName("localhost"); class TestURLRequestContext : public URLRequestContext { public: TestURLRequestContext() { - proxy_service_ = new net::ProxyService(new net::ProxyResolverNull); + proxy_service_ = net::ProxyService::CreateNull(); http_transaction_factory_ = net::HttpNetworkLayer::CreateFactory(proxy_service_); } -- cgit v1.1