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

Side by Side Diff: chrome/browser/io_thread.cc

Issue 430643002: Correcting the version field in the Chrome-Proxy header to be the chromium build and patch number. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Fixing comment format Created 6 years, 4 months 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
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 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 "chrome/browser/io_thread.h" 5 #include "chrome/browser/io_thread.h"
6 6
7 #include <vector> 7 #include <vector>
8 8
9 #include "base/base64.h" 9 #include "base/base64.h"
10 #include "base/bind.h" 10 #include "base/bind.h"
(...skipping 633 matching lines...) Expand 10 before | Expand all | Expand 10 after
644 int drp_flags = DataReductionProxyParams::kFallbackAllowed; 644 int drp_flags = DataReductionProxyParams::kFallbackAllowed;
645 if (DataReductionProxyParams::IsIncludedInFieldTrial()) 645 if (DataReductionProxyParams::IsIncludedInFieldTrial())
646 drp_flags |= DataReductionProxyParams::kAllowed; 646 drp_flags |= DataReductionProxyParams::kAllowed;
647 if (DataReductionProxyParams::IsIncludedInAlternativeFieldTrial()) 647 if (DataReductionProxyParams::IsIncludedInAlternativeFieldTrial())
648 drp_flags |= DataReductionProxyParams::kAlternativeAllowed; 648 drp_flags |= DataReductionProxyParams::kAlternativeAllowed;
649 if (DataReductionProxyParams::IsIncludedInPromoFieldTrial()) 649 if (DataReductionProxyParams::IsIncludedInPromoFieldTrial())
650 drp_flags |= DataReductionProxyParams::kPromoAllowed; 650 drp_flags |= DataReductionProxyParams::kPromoAllowed;
651 DataReductionProxyParams* proxy_params = 651 DataReductionProxyParams* proxy_params =
652 new DataReductionProxyParams(drp_flags); 652 new DataReductionProxyParams(drp_flags);
653 globals_->data_reduction_proxy_params.reset(proxy_params); 653 globals_->data_reduction_proxy_params.reset(proxy_params);
654 chrome::VersionInfo version_info;
654 globals_->data_reduction_proxy_auth_request_handler.reset( 655 globals_->data_reduction_proxy_auth_request_handler.reset(
655 new DataReductionProxyAuthRequestHandler(proxy_params)); 656 new DataReductionProxyAuthRequestHandler(
657 proxy_params, version_info.Version()));
bengr 2014/07/30 00:16:47 I would pass just the build and patch here. The au
megjablon 2014/07/30 20:37:17 Done.
656 globals_->on_resolve_proxy_handler = 658 globals_->on_resolve_proxy_handler =
657 ChromeNetworkDelegate::OnResolveProxyHandler( 659 ChromeNetworkDelegate::OnResolveProxyHandler(
658 base::Bind(data_reduction_proxy::OnResolveProxyHandler)); 660 base::Bind(data_reduction_proxy::OnResolveProxyHandler));
659 DataReductionProxyUsageStats* proxy_usage_stats = 661 DataReductionProxyUsageStats* proxy_usage_stats =
660 new DataReductionProxyUsageStats(proxy_params, 662 new DataReductionProxyUsageStats(proxy_params,
661 BrowserThread::GetMessageLoopProxyForThread(BrowserThread::UI), 663 BrowserThread::GetMessageLoopProxyForThread(BrowserThread::UI),
662 BrowserThread::GetMessageLoopProxyForThread(BrowserThread::IO)); 664 BrowserThread::GetMessageLoopProxyForThread(BrowserThread::IO));
663 network_delegate->set_data_reduction_proxy_params(proxy_params); 665 network_delegate->set_data_reduction_proxy_params(proxy_params);
664 globals_->data_reduction_proxy_usage_stats.reset(proxy_usage_stats); 666 globals_->data_reduction_proxy_usage_stats.reset(proxy_usage_stats);
665 network_delegate->set_data_reduction_proxy_usage_stats(proxy_usage_stats); 667 network_delegate->set_data_reduction_proxy_usage_stats(proxy_usage_stats);
(...skipping 715 matching lines...) Expand 10 before | Expand all | Expand 10 after
1381 net::QuicVersionVector supported_versions = net::QuicSupportedVersions(); 1383 net::QuicVersionVector supported_versions = net::QuicSupportedVersions();
1382 for (size_t i = 0; i < supported_versions.size(); ++i) { 1384 for (size_t i = 0; i < supported_versions.size(); ++i) {
1383 net::QuicVersion version = supported_versions[i]; 1385 net::QuicVersion version = supported_versions[i];
1384 if (net::QuicVersionToString(version) == quic_version) { 1386 if (net::QuicVersionToString(version) == quic_version) {
1385 return version; 1387 return version;
1386 } 1388 }
1387 } 1389 }
1388 1390
1389 return net::QUIC_VERSION_UNSUPPORTED; 1391 return net::QUIC_VERSION_UNSUPPORTED;
1390 } 1392 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698