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

Unified Diff: components/data_reduction_proxy/core/browser/data_reduction_proxy_auth_request_handler.cc

Issue 863203009: Store Proxy Servers as proxy servers and not GURLs. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Fixed failing test code. Created 5 years, 10 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 side-by-side diff with in-line comments
Download patch
Index: components/data_reduction_proxy/core/browser/data_reduction_proxy_auth_request_handler.cc
diff --git a/components/data_reduction_proxy/core/browser/data_reduction_proxy_auth_request_handler.cc b/components/data_reduction_proxy/core/browser/data_reduction_proxy_auth_request_handler.cc
index b4bad4fcee32e16f121f3c2a25ef6b9062c5ef41..768db6682f1ba3a67c663ffc0f39d6b7f9d07122 100644
--- a/components/data_reduction_proxy/core/browser/data_reduction_proxy_auth_request_handler.cc
+++ b/components/data_reduction_proxy/core/browser/data_reduction_proxy_auth_request_handler.cc
@@ -20,7 +20,6 @@
#include "net/base/host_port_pair.h"
#include "net/proxy/proxy_server.h"
#include "net/url_request/url_request.h"
-#include "url/gurl.h"
#if !defined(OS_ANDROID) && !defined(OS_IOS)
#include "google_apis/google_api_keys.h"
@@ -241,9 +240,9 @@ void DataReductionProxyAuthRequestHandler::MaybeAddRequestHeaderImpl(
return;
if (data_reduction_proxy_params_ &&
data_reduction_proxy_params_->IsDataReductionProxy(proxy_server, NULL) &&
- net::HostPortPair::FromURL(
- data_reduction_proxy_params_->ssl_origin()).Equals(
- proxy_server) == expect_ssl) {
+ ((data_reduction_proxy_params_->ssl_origin().is_valid() &&
+ data_reduction_proxy_params_->ssl_origin().host_port_pair().Equals(
+ proxy_server)) == expect_ssl)) {
AddAuthorizationHeader(request_headers);
}
}

Powered by Google App Engine
This is Rietveld 408576698