Title: [149489] tags/Safari-537.40/Source/WebKit2
Revision
149489
Author
[email protected]
Date
2013-05-02 10:45:24 -0700 (Thu, 02 May 2013)

Log Message

Merged r149488.  <rdar://problem/13787297>

Modified Paths

Diff

Modified: tags/Safari-537.40/Source/WebKit2/ChangeLog (149488 => 149489)


--- tags/Safari-537.40/Source/WebKit2/ChangeLog	2013-05-02 16:56:29 UTC (rev 149488)
+++ tags/Safari-537.40/Source/WebKit2/ChangeLog	2013-05-02 17:45:24 UTC (rev 149489)
@@ -1,3 +1,19 @@
+2013-05-02  Lucas Forschler  <[email protected]>
+
+        Merge r149488
+
+    2013-05-01  Alexey Proskuryakov  <[email protected]>
+
+            REGRESSION (r149422): -[WKBrowsingContextController loadFileURL:restrictToFilesWithin:]
+            broken when second argument is nil
+            https://bugs.webkit.org/show_bug.cgi?id=115505
+            <rdar://problem/13787297>
+
+            Reviewed by Darin Adler.
+
+            * UIProcess/WebPageProxy.cpp: (WebKit::WebPageProxy::loadFile): Pass a URL string
+            to assumeReadAccessToBaseURL, as this is what it takes.
+
 2013-05-01  Martin Robinson  <[email protected]>
 
         [GTK] [WebKit2] Documentation for webkit_web_view_run_javascript should indicate what happens when _javascript_ is disabled

Modified: tags/Safari-537.40/Source/WebKit2/UIProcess/WebPageProxy.cpp (149488 => 149489)


--- tags/Safari-537.40/Source/WebKit2/UIProcess/WebPageProxy.cpp	2013-05-02 16:56:29 UTC (rev 149488)
+++ tags/Safari-537.40/Source/WebKit2/UIProcess/WebPageProxy.cpp	2013-05-02 17:45:24 UTC (rev 149489)
@@ -740,18 +740,20 @@
     if (!fileURL.isLocalFile())
         return;
 
-    String resourceDirectoryPath;
-    if (!resourceDirectoryURLString.isNull()) {
-        KURL resourceDirectoryURL = KURL(KURL(), resourceDirectoryURLString);
+    KURL resourceDirectoryURL;
+    if (resourceDirectoryURLString.isNull())
+        resourceDirectoryURL = KURL(ParsedURLString, ASCIILiteral("file:///"));
+    else {
+        resourceDirectoryURL = KURL(KURL(), resourceDirectoryURLString);
         if (!resourceDirectoryURL.isLocalFile())
             return;
-        resourceDirectoryPath = resourceDirectoryURL.fileSystemPath();
-    } else
-        resourceDirectoryPath = ASCIILiteral("/");
+    }
 
+    String resourceDirectoryPath = resourceDirectoryURL.fileSystemPath();
+
     SandboxExtension::Handle sandboxExtensionHandle;
     SandboxExtension::createHandle(resourceDirectoryPath, SandboxExtension::ReadOnly, sandboxExtensionHandle);
-    m_process->assumeReadAccessToBaseURL(resourceDirectoryPath);
+    m_process->assumeReadAccessToBaseURL(resourceDirectoryURL);
     m_process->send(Messages::WebPage::LoadURL(fileURL, sandboxExtensionHandle), m_pageID);
     m_process->responsivenessTimer()->start();
 }
_______________________________________________
webkit-changes mailing list
[email protected]
https://lists.webkit.org/mailman/listinfo/webkit-changes

Reply via email to