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

Unified Diff: webkit/fileapi/file_system_path_manager.cc

Issue 6286038: Add initial code to do filename munging in the FileSystem.... (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: '' Created 9 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: webkit/fileapi/file_system_path_manager.cc
===================================================================
--- webkit/fileapi/file_system_path_manager.cc (revision 74905)
+++ webkit/fileapi/file_system_path_manager.cc (working copy)
@@ -222,7 +222,7 @@
bool FileSystemPathManager::CrackFileSystemPath(
const FilePath& path, GURL* origin_url, FileSystemType* type,
- FilePath* virtual_path) const {
+ FilePath* root, FilePath* virtual_path) const {
// Any paths that includes parent references are considered invalid.
if (path.ReferencesParent())
return false;
@@ -275,6 +275,13 @@
if (type)
*type = cracked_type;
+ if (root) {
+ FilePath temp = base_path_;
+ temp = temp.Append(components[0]);
+ temp = temp.Append(components[1]);
+ *root = temp.Append(components[2]);
+ }
+
if (virtual_path) {
virtual_path->clear();
for (size_t i = 3; i < components.size(); ++i)

Powered by Google App Engine
This is Rietveld 408576698