Title: [234240] branches/safari-606-branch/Source/WebCore
Revision
234240
Author
[email protected]
Date
2018-07-26 00:14:55 -0700 (Thu, 26 Jul 2018)

Log Message

Cherry-pick r234140. rdar://problem/42606763

    REGRESSION(r234055): inverted return values in MediaPlayer::wouldTaintOrigin()
    https://bugs.webkit.org/show_bug.cgi?id=187944

    Reviewed by Carlos Garcia Campos.

    The MediaPlayer::wouldTaintOrigin(), as introduced in r234055, should
    return false when the URL protocol is `data:`, and should return true
    when the given SecurityOrigin cannot access the media URL.

    This matches behavior of CanvasRenderingContext::wouldTaintOrigin()
    which the new method falls back to when the MediaPlayerPrivate
    implementation doesn't or can't determine the would-taint result.

    This fixes a bunch of failing and timing-out WebGL test cases on ports
    using GStreamer (on which the MediaPlayerPrivate derivate doesn't
    implement the wouldTaintOrigin() method).

    * platform/graphics/MediaPlayer.cpp:
    (WebCore::MediaPlayer::wouldTaintOrigin const):

    git-svn-id: https://svn.webkit.org/repository/webkit/trunk@234140 268f45cc-cd09-0410-ab3c-d52691b4dbfc

Modified Paths

Diff

Modified: branches/safari-606-branch/Source/WebCore/ChangeLog (234239 => 234240)


--- branches/safari-606-branch/Source/WebCore/ChangeLog	2018-07-26 07:14:53 UTC (rev 234239)
+++ branches/safari-606-branch/Source/WebCore/ChangeLog	2018-07-26 07:14:55 UTC (rev 234240)
@@ -1,5 +1,54 @@
 2018-07-25  Babak Shafiei  <[email protected]>
 
+        Cherry-pick r234140. rdar://problem/42606763
+
+    REGRESSION(r234055): inverted return values in MediaPlayer::wouldTaintOrigin()
+    https://bugs.webkit.org/show_bug.cgi?id=187944
+    
+    Reviewed by Carlos Garcia Campos.
+    
+    The MediaPlayer::wouldTaintOrigin(), as introduced in r234055, should
+    return false when the URL protocol is `data:`, and should return true
+    when the given SecurityOrigin cannot access the media URL.
+    
+    This matches behavior of CanvasRenderingContext::wouldTaintOrigin()
+    which the new method falls back to when the MediaPlayerPrivate
+    implementation doesn't or can't determine the would-taint result.
+    
+    This fixes a bunch of failing and timing-out WebGL test cases on ports
+    using GStreamer (on which the MediaPlayerPrivate derivate doesn't
+    implement the wouldTaintOrigin() method).
+    
+    * platform/graphics/MediaPlayer.cpp:
+    (WebCore::MediaPlayer::wouldTaintOrigin const):
+    
+    
+    git-svn-id: https://svn.webkit.org/repository/webkit/trunk@234140 268f45cc-cd09-0410-ab3c-d52691b4dbfc
+
+    2018-07-24  Zan Dobersek  <[email protected]>
+
+            REGRESSION(r234055): inverted return values in MediaPlayer::wouldTaintOrigin()
+            https://bugs.webkit.org/show_bug.cgi?id=187944
+
+            Reviewed by Carlos Garcia Campos.
+
+            The MediaPlayer::wouldTaintOrigin(), as introduced in r234055, should
+            return false when the URL protocol is `data:`, and should return true
+            when the given SecurityOrigin cannot access the media URL.
+
+            This matches behavior of CanvasRenderingContext::wouldTaintOrigin()
+            which the new method falls back to when the MediaPlayerPrivate
+            implementation doesn't or can't determine the would-taint result.
+
+            This fixes a bunch of failing and timing-out WebGL test cases on ports
+            using GStreamer (on which the MediaPlayerPrivate derivate doesn't
+            implement the wouldTaintOrigin() method).
+
+            * platform/graphics/MediaPlayer.cpp:
+            (WebCore::MediaPlayer::wouldTaintOrigin const):
+
+2018-07-25  Babak Shafiei  <[email protected]>
+
         Cherry-pick r234113. rdar://problem/42604546
 
     WebCore::primaryScreenDisplayID() always return 0

Modified: branches/safari-606-branch/Source/WebCore/platform/graphics/MediaPlayer.cpp (234239 => 234240)


--- branches/safari-606-branch/Source/WebCore/platform/graphics/MediaPlayer.cpp	2018-07-26 07:14:53 UTC (rev 234239)
+++ branches/safari-606-branch/Source/WebCore/platform/graphics/MediaPlayer.cpp	2018-07-26 07:14:55 UTC (rev 234240)
@@ -1053,9 +1053,9 @@
         return wouldTaint.value();
 
     if (m_url.protocolIsData())
-        return true;
+        return false;
 
-    return origin.canRequest(m_url);
+    return !origin.canRequest(m_url);
 }
 
 MediaPlayer::MovieLoadType MediaPlayer::movieLoadType() const
_______________________________________________
webkit-changes mailing list
[email protected]
https://lists.webkit.org/mailman/listinfo/webkit-changes

Reply via email to