[Webkit-unassigned] [Bug 54774] [fileapi] Implement LocalFileSystem.resolveFileSystemURI

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Fri Feb 18 19:01:15 PST 2011


https://bugs.webkit.org/show_bug.cgi?id=54774





--- Comment #4 from Eric U. <ericu at chromium.org>  2011-02-18 19:01:15 PST ---
(From update of attachment 83025)
View in context: https://bugs.webkit.org/attachment.cgi?id=83025&action=review

> LayoutTests/fast/filesystem/resources/resolve-uri.js:14
> +    testFailed("Error occured:" + error.code);

Typo: occurred

> LayoutTests/fast/filesystem/resources/resolve-uri.js:38
> +var jsTestIsAsync = true;

I think it's worth testing more than one URL.
For example, try one with a directory, try both temporary and persistent, try the root directory, try removing the entry before resolving the URL.
Also, generate some by hand and test a few kinds of malformed URLs, and try directories with and without the trailing slash.

> Source/WebCore/fileapi/DOMFileSystemBase.cpp:53
> +const char DOMFileSystemBase::kTemporaryPathString[] = "temporary";

Now that we've got these constants defined, we should really use them in toURI as well.

> Source/WebCore/fileapi/DOMFileSystemBase.cpp:62
> +    if (path.isEmpty() || !path[0] == '/')

Do you mean:

    path[0] != '/'

?

> Source/WebCore/fileapi/DOMFileSystemBase.cpp:75
> +    if (path.isEmpty() || !path[0] == '/')

Same here.

> Source/WebCore/page/DOMWindow.cpp:766
> +    if (!AsyncFileSystem::isAvailable() || !securityOrigin->canAccessFileSystem() || !securityOrigin->canRequest(parsedURL)) {

I'm not sure this is strict enough.  Should the fact that the security origin can load from this URL be enough to grant it [writeable] access to the Entry?
Currently we're talking about not letting any cross-origin requests be made at all, but if we should relax that, we wouldn't necessarily want to allow this as well.

-- 
Configure bugmail: https://bugs.webkit.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.



More information about the webkit-unassigned mailing list