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

Unified Diff: webkit/fileapi/local_file_system_file_util.cc

Issue 6864040: Fixed file/directory url resolution for external mount point provider. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: '' Created 9 years, 8 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: webkit/fileapi/local_file_system_file_util.cc
===================================================================
--- webkit/fileapi/local_file_system_file_util.cc (revision 82259)
+++ webkit/fileapi/local_file_system_file_util.cc (working copy)
@@ -44,6 +44,20 @@
context, local_path, created);
}
+PlatformFileError LocalFileSystemFileUtil::GetLocalFilePath(
+ FileSystemOperationContext* context,
+ const FilePath& virtual_path,
+ FilePath* local_path) {
+ FilePath path =
+ GetLocalPath(context, context->src_origin_url(), context->src_type(),
+ virtual_path);
+ if (path.empty())
+ return base::PLATFORM_FILE_ERROR_NOT_FOUND;
+
+ *local_path = path;
+ return base::PLATFORM_FILE_OK;
+}
+
PlatformFileError LocalFileSystemFileUtil::GetFileInfo(
FileSystemOperationContext* context,
const FilePath& file_path,
@@ -170,7 +184,8 @@
FileSystemType type,
const FilePath& virtual_path) {
FilePath root = context->file_system_context()->path_manager()->
- GetFileSystemRootPathOnFileThread(origin_url, type, virtual_path, false);
+ ValidateFileSystemRootAndGetPathOnFileThread(origin_url, type,
+ virtual_path, false);
if (root.empty())
return FilePath();
return root.Append(virtual_path);

Powered by Google App Engine
This is Rietveld 408576698