Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(129)

Side by Side Diff: components/component_updater/configurator_impl.cc

Issue 1441223002: Disable BITS downloader until stability issues due to crbug.com/475872 (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 years, 1 month ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 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 "components/component_updater/configurator_impl.h" 5 #include "components/component_updater/configurator_impl.h"
6 6
7 #include <algorithm> 7 #include <algorithm>
8 8
9 #include "base/command_line.h" 9 #include "base/command_line.h"
10 #include "base/compiler_specific.h" 10 #include "base/compiler_specific.h"
(...skipping 91 matching lines...) Expand 10 before | Expand all | Expand 10 after
102 background_downloads_enabled_(false), 102 background_downloads_enabled_(false),
103 fallback_to_alt_source_url_enabled_(false) { 103 fallback_to_alt_source_url_enabled_(false) {
104 // Parse comma-delimited debug flags. 104 // Parse comma-delimited debug flags.
105 std::vector<std::string> switch_values = base::SplitString( 105 std::vector<std::string> switch_values = base::SplitString(
106 cmdline->GetSwitchValueASCII(switches::kComponentUpdater), ",", 106 cmdline->GetSwitchValueASCII(switches::kComponentUpdater), ",",
107 base::KEEP_WHITESPACE, base::SPLIT_WANT_NONEMPTY); 107 base::KEEP_WHITESPACE, base::SPLIT_WANT_NONEMPTY);
108 fast_update_ = HasSwitchValue(switch_values, kSwitchFastUpdate); 108 fast_update_ = HasSwitchValue(switch_values, kSwitchFastUpdate);
109 pings_enabled_ = !HasSwitchValue(switch_values, kSwitchDisablePings); 109 pings_enabled_ = !HasSwitchValue(switch_values, kSwitchDisablePings);
110 deltas_enabled_ = !HasSwitchValue(switch_values, kSwitchDisableDeltaUpdates); 110 deltas_enabled_ = !HasSwitchValue(switch_values, kSwitchDisableDeltaUpdates);
111 111
112 #if defined(OS_WIN) 112 // Disable BITS on all platforms in all cases until crbug.com/475872 is
113 background_downloads_enabled_ = 113 // resolved.
114 !HasSwitchValue(switch_values, kSwitchDisableBackgroundDownloads);
115 #else
116 background_downloads_enabled_ = false; 114 background_downloads_enabled_ = false;
117 #endif
118 115
119 const std::string switch_url_source = 116 const std::string switch_url_source =
120 GetSwitchArgument(switch_values, kSwitchUrlSource); 117 GetSwitchArgument(switch_values, kSwitchUrlSource);
121 if (!switch_url_source.empty()) { 118 if (!switch_url_source.empty()) {
122 url_source_override_ = GURL(switch_url_source); 119 url_source_override_ = GURL(switch_url_source);
123 DCHECK(url_source_override_.is_valid()); 120 DCHECK(url_source_override_.is_valid());
124 } 121 }
125 122
126 if (HasSwitchValue(switch_values, kSwitchRequestParam)) 123 if (HasSwitchValue(switch_values, kSwitchRequestParam))
127 extra_info_ += "testrequest=\"1\""; 124 extra_info_ += "testrequest=\"1\"";
(...skipping 62 matching lines...) Expand 10 before | Expand all | Expand 10 after
190 187
191 bool ConfiguratorImpl::UseBackgroundDownloader() const { 188 bool ConfiguratorImpl::UseBackgroundDownloader() const {
192 return background_downloads_enabled_; 189 return background_downloads_enabled_;
193 } 190 }
194 191
195 void ConfiguratorImpl::set_enable_alt_source_url(bool enable_alt_source_url) { 192 void ConfiguratorImpl::set_enable_alt_source_url(bool enable_alt_source_url) {
196 fallback_to_alt_source_url_enabled_ = enable_alt_source_url; 193 fallback_to_alt_source_url_enabled_ = enable_alt_source_url;
197 } 194 }
198 195
199 } // namespace component_updater 196 } // namespace component_updater
OLDNEW
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698