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

Unified Diff: net/url_request/url_request_file_job.cc

Issue 2790073002: wip (Closed)
Patch Set: Created 3 years, 9 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: net/url_request/url_request_file_job.cc
diff --git a/net/url_request/url_request_file_job.cc b/net/url_request/url_request_file_job.cc
index 4924e02349100a852f8c4499472ea42bef3feb6b..57bc3674fde20f87d7463e801e43e174f6978e59 100644
--- a/net/url_request/url_request_file_job.cc
+++ b/net/url_request/url_request_file_job.cc
@@ -178,6 +178,10 @@ void URLRequestFileJob::SetExtraRequestHeaders(
}
}
+bool URLRequestFileJob::OnFetchMetaInfo(const FileMetaInfo& meta_info) {
+ return true;
+}
+
void URLRequestFileJob::OnOpenComplete(int result) {}
void URLRequestFileJob::OnSeekComplete(int64_t result) {}
@@ -208,9 +212,13 @@ void URLRequestFileJob::FetchMetaInfo(const base::FilePath& file_path,
// done in WorkerPool.
meta_info->mime_type_result = GetMimeTypeFromFile(file_path,
&meta_info->mime_type);
+ meta_info->absolute_path = base::MakeAbsoluteFilePath(file_path);
}
void URLRequestFileJob::DidFetchMetaInfo(const FileMetaInfo* meta_info) {
+ if (!OnFetchMetaInfo(*meta_info))
+ return;
+
meta_info_ = *meta_info;
// We use URLRequestFileJob to handle files as well as directories without
« chrome/browser/profiles/profile_io_data.cc ('K') | « net/url_request/url_request_file_job.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698