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

Unified Diff: content/browser/download/download_item_impl.cc

Issue 2727143005: Change FindNextSliceToDownload() into FindSlicesToDownload() (Closed)
Patch Set: adding TODO and comments Created 3 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: content/browser/download/download_item_impl.cc
diff --git a/content/browser/download/download_item_impl.cc b/content/browser/download/download_item_impl.cc
index 95e5aac012ad7fa92b600ca148f8b7419c6d811a..fded203421d1535fa50b5782aa67e16713c4accb 100644
--- a/content/browser/download/download_item_impl.cc
+++ b/content/browser/download/download_item_impl.cc
@@ -1955,9 +1955,10 @@ void DownloadItemImpl::ResumeInterruptedDownload(
storage_partition->GetURLRequestContext()));
download_params->set_file_path(GetFullPath());
if (received_slices_.size() > 0) {
- ReceivedSlice next_slice = FindNextSliceToDownload(received_slices_);
- download_params->set_offset(next_slice.offset);
- download_params->set_length(next_slice.received_bytes);
+ std::vector<DownloadItem::ReceivedSlice> slices_to_download
+ = FindSlicesToDownload(received_slices_);
+ download_params->set_offset(slices_to_download[0].offset);
+ download_params->set_length(slices_to_download[0].received_bytes);
} else {
download_params->set_offset(GetReceivedBytes());
}
« no previous file with comments | « no previous file | content/browser/download/download_job_factory.cc » ('j') | content/browser/download/parallel_download_job.cc » ('J')

Powered by Google App Engine
This is Rietveld 408576698