Title: [276352] trunk/Source/WebCore
Revision
276352
Author
[email protected]
Date
2021-04-21 01:44:42 -0700 (Wed, 21 Apr 2021)

Log Message

Use BlobURL::getOriginURL in more places
https://bugs.webkit.org/show_bug.cgi?id=224857

Reviewed by Alex Christensen.

Covered by existing tests.

* loader/PolicyChecker.cpp:
(WebCore::FrameLoader::PolicyChecker::extendBlobURLLifetimeIfNecessary const):

Modified Paths

Diff

Modified: trunk/Source/WebCore/ChangeLog (276351 => 276352)


--- trunk/Source/WebCore/ChangeLog	2021-04-21 07:38:21 UTC (rev 276351)
+++ trunk/Source/WebCore/ChangeLog	2021-04-21 08:44:42 UTC (rev 276352)
@@ -1,3 +1,15 @@
+2021-04-21  Youenn Fablet  <[email protected]>
+
+        Use BlobURL::getOriginURL in more places
+        https://bugs.webkit.org/show_bug.cgi?id=224857
+
+        Reviewed by Alex Christensen.
+
+        Covered by existing tests.
+
+        * loader/PolicyChecker.cpp:
+        (WebCore::FrameLoader::PolicyChecker::extendBlobURLLifetimeIfNecessary const):
+
 2021-04-21  Tim Horton  <[email protected]>
 
         Long-pressing a data detectors link causes the link to be followed

Modified: trunk/Source/WebCore/loader/PolicyChecker.cpp (276351 => 276352)


--- trunk/Source/WebCore/loader/PolicyChecker.cpp	2021-04-21 07:38:21 UTC (rev 276351)
+++ trunk/Source/WebCore/loader/PolicyChecker.cpp	2021-04-21 08:44:42 UTC (rev 276352)
@@ -111,8 +111,9 @@
         return { };
 
     // Create a new temporary blobURL in case this one gets revoked during the asynchronous navigation policy decision.
-    URL temporaryBlobURL = BlobURL::createPublicURL(&m_frame.document()->securityOrigin());
-    ThreadableBlobRegistry::registerBlobURL(&m_frame.document()->securityOrigin(), temporaryBlobURL, request.url());
+    auto origin = SecurityOrigin::create(BlobURL::getOriginURL(request.url()));
+    URL temporaryBlobURL = BlobURL::createPublicURL(origin.ptr());
+    ThreadableBlobRegistry::registerBlobURL(origin.ptr(), temporaryBlobURL, request.url());
     request.setURL(temporaryBlobURL);
     if (loader)
         loader->request().setURL(temporaryBlobURL);
_______________________________________________
webkit-changes mailing list
[email protected]
https://lists.webkit.org/mailman/listinfo/webkit-changes

Reply via email to