Title: [241742] trunk/Source/WebCore
- Revision
- 241742
- Author
- jer.no...@apple.com
- Date
- 2019-02-18 15:12:33 -0800 (Mon, 18 Feb 2019)
Log Message
-[AVSampleBufferDisplayLayer player]: Unrecognized selector crash
https://bugs.webkit.org/show_bug.cgi?id=194790
<rdar://problem/33866742>
Reviewed by Jon Lee.
Ensure that a WebVideoContainerLayer's sole sublayer is actually an AVPlayerLayer (and not
an AVSampleBufferDisplayLayer) before reporting that the layer type is LayerTypeAVPlayerLayer.
* platform/graphics/ca/cocoa/PlatformCALayerCocoa.mm:
(WebCore::PlatformCALayerCocoa::layerTypeForPlatformLayer):
Modified Paths
Diff
Modified: trunk/Source/WebCore/ChangeLog (241741 => 241742)
--- trunk/Source/WebCore/ChangeLog 2019-02-18 22:58:46 UTC (rev 241741)
+++ trunk/Source/WebCore/ChangeLog 2019-02-18 23:12:33 UTC (rev 241742)
@@ -1,3 +1,17 @@
+2019-02-18 Jer Noble <jer.no...@apple.com>
+
+ -[AVSampleBufferDisplayLayer player]: Unrecognized selector crash
+ https://bugs.webkit.org/show_bug.cgi?id=194790
+ <rdar://problem/33866742>
+
+ Reviewed by Jon Lee.
+
+ Ensure that a WebVideoContainerLayer's sole sublayer is actually an AVPlayerLayer (and not
+ an AVSampleBufferDisplayLayer) before reporting that the layer type is LayerTypeAVPlayerLayer.
+
+ * platform/graphics/ca/cocoa/PlatformCALayerCocoa.mm:
+ (WebCore::PlatformCALayerCocoa::layerTypeForPlatformLayer):
+
2019-02-18 Joseph Pecoraro <pecor...@apple.com>
Web Inspector: Better categorize CPU usage per-thread / worker
Modified: trunk/Source/WebCore/platform/graphics/ca/cocoa/PlatformCALayerCocoa.mm (241741 => 241742)
--- trunk/Source/WebCore/platform/graphics/ca/cocoa/PlatformCALayerCocoa.mm 2019-02-18 22:58:46 UTC (rev 241741)
+++ trunk/Source/WebCore/platform/graphics/ca/cocoa/PlatformCALayerCocoa.mm 2019-02-18 23:12:33 UTC (rev 241742)
@@ -202,9 +202,14 @@
PlatformCALayer::LayerType PlatformCALayerCocoa::layerTypeForPlatformLayer(PlatformLayer* layer)
{
- if ([layer isKindOfClass:getAVPlayerLayerClass()] || [layer isKindOfClass:objc_getClass("WebVideoContainerLayer")])
+ if ([layer isKindOfClass:getAVPlayerLayerClass()])
return LayerTypeAVPlayerLayer;
+ if ([layer isKindOfClass:objc_getClass("WebVideoContainerLayer")]
+ && layer.sublayers.count == 1
+ && [layer.sublayers[0] isKindOfClass:getAVPlayerLayerClass()])
+ return LayerTypeAVPlayerLayer;
+
if ([layer isKindOfClass:[WebGLLayer class]])
return LayerTypeContentsProvidedLayer;
_______________________________________________
webkit-changes mailing list
webkit-changes@lists.webkit.org
https://lists.webkit.org/mailman/listinfo/webkit-changes