Chromium Code Reviews| Index: components/data_reduction_proxy/core/common/data_reduction_proxy_params.cc |
| diff --git a/components/data_reduction_proxy/core/common/data_reduction_proxy_params.cc b/components/data_reduction_proxy/core/common/data_reduction_proxy_params.cc |
| index 24ae0085b2de7ff912435c77eb7cfe64a8ec3484..60b6b49f190f3cb2946a72793355e455050b7b4d 100644 |
| --- a/components/data_reduction_proxy/core/common/data_reduction_proxy_params.cc |
| +++ b/components/data_reduction_proxy/core/common/data_reduction_proxy_params.cc |
| @@ -315,7 +315,8 @@ bool DataReductionProxyParams::WasDataReductionProxyUsed( |
| bool DataReductionProxyParams::IsDataReductionProxy( |
| const net::HostPortPair& host_port_pair, |
| DataReductionProxyTypeInfo* proxy_info) const { |
| - if (net::HostPortPair::FromURL(origin()).Equals(host_port_pair)) { |
| + if (allowed() && |
|
bengr
2014/10/29 23:41:26
Why is this now necessary?
Not at Google. Contact bengr
2014/10/30 00:05:03
Discussed in person. Was always needed for correct
|
| + net::HostPortPair::FromURL(origin()).Equals(host_port_pair)) { |
| if (proxy_info) { |
| proxy_info->proxy_servers.first = origin(); |
| if (fallback_allowed()) |
| @@ -333,7 +334,8 @@ bool DataReductionProxyParams::IsDataReductionProxy( |
| } |
| return true; |
| } |
| - if (net::HostPortPair::FromURL(alt_origin()).Equals(host_port_pair)) { |
| + if (alternative_allowed() && |
| + net::HostPortPair::FromURL(alt_origin()).Equals(host_port_pair)) { |
| if (proxy_info) { |
| proxy_info->proxy_servers.first = alt_origin(); |
| proxy_info->is_alternative = true; |