Chromium Code Reviews| Index: content/child/url_loader_client_impl.cc |
| diff --git a/content/child/url_loader_client_impl.cc b/content/child/url_loader_client_impl.cc |
| index 04aee613ace7c63b19db4b3b8c5f995f9cf9ba30..f41f661e079f147b83637d35c9e1851f633bb89f 100644 |
| --- a/content/child/url_loader_client_impl.cc |
| +++ b/content/child/url_loader_client_impl.cc |
| @@ -134,6 +134,13 @@ void URLLoaderClientImpl::OnDataDownloaded(int64_t data_len, |
| Dispatch(ResourceMsg_DataDownloaded(request_id_, data_len, encoded_data_len)); |
| } |
| +void URLLoaderClientImpl::OnReceiveCachedMetadata( |
| + const std::vector<uint8_t>& data) { |
| + const char* ptr = reinterpret_cast<const char*>(data.data()); |
|
mmenke
2017/01/17 18:39:57
Again, suggest replacing ptr with data
yhirano
2017/01/18 06:22:42
I'm using data_ptr as we are already using the nam
|
| + Dispatch(ResourceMsg_ReceivedCachedMetadata( |
| + request_id_, std::vector<char>(ptr, ptr + data.size()))); |
|
dcheng
2017/01/14 11:30:17
And I guess this is another copy =(
Is there any
yhirano
2017/01/16 05:25:46
This is needed to reuse the current ResourceDispat
dcheng
2017/01/18 00:23:53
Sort of... we have to reinterpret_cast the origina
yhirano
2017/01/18 06:22:42
Acknowledged.
|
| +} |
| + |
| void URLLoaderClientImpl::OnTransferSizeUpdated(int32_t transfer_size_diff) { |
| if (is_deferred_) { |
| accumulated_transfer_size_diff_during_deferred_ += transfer_size_diff; |