diff options
author | cevans@chromium.org <cevans@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2011-06-20 00:28:21 +0000 |
---|---|---|
committer | cevans@chromium.org <cevans@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2011-06-20 00:28:21 +0000 |
commit | dc9eb03de1299875489c1dd3724d45da42b7bff7 (patch) | |
tree | 9011eb3dd26b6f5fb0a02474ab3a0e546a1424ea /net/proxy | |
parent | 69c14c30e724c382358018e511a66641386e90c8 (diff) | |
download | chromium_src-dc9eb03de1299875489c1dd3724d45da42b7bff7.zip chromium_src-dc9eb03de1299875489c1dd3724d45da42b7bff7.tar.gz chromium_src-dc9eb03de1299875489c1dd3724d45da42b7bff7.tar.bz2 |
Revert 89629 - Revert 89486 - Revert 87047 - Revert 86422 - Make DHCP WPAD on by default.
Reason: Turning back on for trunk to collect data as performance worries are addressed.
BUG=18575,84047
TEST=Run Chrome on Windows without any flags. Enable auto-detect in proxy configuration. Net log should show attempts to auto-detect via DHCP.
Review URL: http://codereview.chromium.org/7167016
TBR=joi@chromium.org
NOTE: I'll roll it back in if it turns out this wasn't the problem.
Review URL: http://codereview.chromium.org/7200025
TBR=cevans@chromium.org
Review URL: http://codereview.chromium.org/7204024
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@89633 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'net/proxy')
-rw-r--r-- | net/proxy/dhcp_proxy_script_fetcher_factory.cc | 4 | ||||
-rw-r--r-- | net/proxy/dhcp_proxy_script_fetcher_factory.h | 2 | ||||
-rw-r--r-- | net/proxy/dhcp_proxy_script_fetcher_factory_unittest.cc | 6 |
3 files changed, 8 insertions, 4 deletions
diff --git a/net/proxy/dhcp_proxy_script_fetcher_factory.cc b/net/proxy/dhcp_proxy_script_fetcher_factory.cc index faedf86..01ede05 100644 --- a/net/proxy/dhcp_proxy_script_fetcher_factory.cc +++ b/net/proxy/dhcp_proxy_script_fetcher_factory.cc @@ -15,9 +15,7 @@ namespace net { DhcpProxyScriptFetcherFactory::DhcpProxyScriptFetcherFactory() : feature_enabled_(false) { - // TODO(joi): Change this default, and the comment on |set_enabled()|, - // when the time is right. - set_enabled(false); + set_enabled(true); } DhcpProxyScriptFetcher* DhcpProxyScriptFetcherFactory::Create( diff --git a/net/proxy/dhcp_proxy_script_fetcher_factory.h b/net/proxy/dhcp_proxy_script_fetcher_factory.h index 02f1dcd..273f321 100644 --- a/net/proxy/dhcp_proxy_script_fetcher_factory.h +++ b/net/proxy/dhcp_proxy_script_fetcher_factory.h @@ -47,7 +47,7 @@ class NET_API DhcpProxyScriptFetcherFactory { // Attempts to enable/disable the DHCP WPAD feature. Does nothing // if |IsSupported()| returns false. // - // The current default is |enabled() == false|. + // The default is |enabled() == true|. void set_enabled(bool enabled); // Returns true if the DHCP WPAD feature is enabled. Always returns diff --git a/net/proxy/dhcp_proxy_script_fetcher_factory_unittest.cc b/net/proxy/dhcp_proxy_script_fetcher_factory_unittest.cc index 902a41b..97730bc 100644 --- a/net/proxy/dhcp_proxy_script_fetcher_factory_unittest.cc +++ b/net/proxy/dhcp_proxy_script_fetcher_factory_unittest.cc @@ -9,8 +9,10 @@ namespace net { namespace { + TEST(DhcpProxyScriptFetcherFactoryTest, DoNothingWhenDisabled) { DhcpProxyScriptFetcherFactory factory; + factory.set_enabled(false); scoped_ptr<DhcpProxyScriptFetcher> fetcher(factory.Create(NULL)); EXPECT_EQ("", fetcher->GetFetcherName()); } @@ -36,7 +38,11 @@ TEST(DhcpProxyScriptFetcherFactoryTest, IsSupported) { TEST(DhcpProxyScriptFetcherFactoryTest, SetEnabled) { DhcpProxyScriptFetcherFactory factory; +#if defined(OS_WIN) + EXPECT_TRUE(factory.enabled()); +#else EXPECT_FALSE(factory.enabled()); +#endif // defined(OS_WIN) factory.set_enabled(false); EXPECT_FALSE(factory.enabled()); |