| Index: components/data_reduction_proxy/core/browser/data_reduction_proxy_network_delegate.cc
|
| diff --git a/components/data_reduction_proxy/core/browser/data_reduction_proxy_network_delegate.cc b/components/data_reduction_proxy/core/browser/data_reduction_proxy_network_delegate.cc
|
| index c336696ce2d7655e141d41d1d2131656b9e264fe..c2f9c2f5bad8360f401a98be3b64d461cd2fe000 100644
|
| --- a/components/data_reduction_proxy/core/browser/data_reduction_proxy_network_delegate.cc
|
| +++ b/components/data_reduction_proxy/core/browser/data_reduction_proxy_network_delegate.cc
|
| @@ -391,6 +391,25 @@ void DataReductionProxyNetworkDelegate::OnCompletedInternal(
|
| RecordContentLength(*request, request_type, original_content_length);
|
| }
|
|
|
| +void DataReductionProxyNetworkDelegate::OnHeadersReceivedInternal(
|
| + net::URLRequest* request,
|
| + const net::CompletionCallback& callback,
|
| + const net::HttpResponseHeaders* original_response_headers,
|
| + scoped_refptr<net::HttpResponseHeaders>* override_response_headers,
|
| + GURL* allowed_unsafe_redirect_url) {
|
| + if (!original_response_headers)
|
| + return;
|
| + if (IsEmptyImagePreview(*original_response_headers)) {
|
| + DataReductionProxyData* data =
|
| + DataReductionProxyData::GetDataAndCreateIfNecessary(request);
|
| + data->set_lofi_received(true);
|
| + } else if (IsLitePagePreview(*original_response_headers)) {
|
| + DataReductionProxyData* data =
|
| + DataReductionProxyData::GetDataAndCreateIfNecessary(request);
|
| + data->set_lite_page_received(true);
|
| + }
|
| +}
|
| +
|
| void DataReductionProxyNetworkDelegate::CalculateAndRecordDataUsage(
|
| const net::URLRequest& request,
|
| DataReductionProxyRequestType request_type) {
|
|
|