Title: [143785] trunk/Source/WebCore
- Revision
- 143785
- Author
- bda...@apple.com
- Date
- 2013-02-22 13:38:08 -0800 (Fri, 22 Feb 2013)
Log Message
ScrollingStateTree::rootStateNode() should be null-checked since it can be null
https://bugs.webkit.org/show_bug.cgi?id=110631
Reviewed by Simon Fraser.
This is a speculative fix for <rdar://problem/13233090> and
<rdar://problem/12519348>. It is totally possible for rootStateNode() to be null,
so we should null-check it.
* page/scrolling/mac/ScrollingCoordinatorMac.mm:
(WebCore::ScrollingCoordinatorMac::setShouldUpdateScrollLayerPositionOnMainThread):
(WebCore::ScrollingCoordinatorMac::syncChildPositions):
Modified Paths
Diff
Modified: trunk/Source/WebCore/ChangeLog (143784 => 143785)
--- trunk/Source/WebCore/ChangeLog 2013-02-22 21:30:51 UTC (rev 143784)
+++ trunk/Source/WebCore/ChangeLog 2013-02-22 21:38:08 UTC (rev 143785)
@@ -1,3 +1,18 @@
+2013-02-22 Beth Dakin <bda...@apple.com>
+
+ ScrollingStateTree::rootStateNode() should be null-checked since it can be null
+ https://bugs.webkit.org/show_bug.cgi?id=110631
+
+ Reviewed by Simon Fraser.
+
+ This is a speculative fix for <rdar://problem/13233090> and
+ <rdar://problem/12519348>. It is totally possible for rootStateNode() to be null,
+ so we should null-check it.
+
+ * page/scrolling/mac/ScrollingCoordinatorMac.mm:
+ (WebCore::ScrollingCoordinatorMac::setShouldUpdateScrollLayerPositionOnMainThread):
+ (WebCore::ScrollingCoordinatorMac::syncChildPositions):
+
2013-02-22 Mike Reed <r...@google.com>
Check for null-device when calling createCompatibleDevice
Modified: trunk/Source/WebCore/page/scrolling/mac/ScrollingCoordinatorMac.mm (143784 => 143785)
--- trunk/Source/WebCore/page/scrolling/mac/ScrollingCoordinatorMac.mm 2013-02-22 21:30:51 UTC (rev 143784)
+++ trunk/Source/WebCore/page/scrolling/mac/ScrollingCoordinatorMac.mm 2013-02-22 21:38:08 UTC (rev 143785)
@@ -314,6 +314,9 @@
void ScrollingCoordinatorMac::setShouldUpdateScrollLayerPositionOnMainThread(MainThreadScrollingReasons reasons)
{
+ if (!m_scrollingStateTree->rootStateNode())
+ return;
+
// The FrameView's GraphicsLayer is likely to be out-of-synch with the PlatformLayer
// at this point. So we'll update it before we switch back to main thread scrolling
// in order to avoid layer positioning bugs.
@@ -340,6 +343,9 @@
void ScrollingCoordinatorMac::syncChildPositions(const LayoutRect& viewportRect)
{
+ if (!m_scrollingStateTree->rootStateNode())
+ return;
+
Vector<OwnPtr<ScrollingStateNode> >* children = m_scrollingStateTree->rootStateNode()->children();
if (!children)
return;
_______________________________________________
webkit-changes mailing list
webkit-changes@lists.webkit.org
https://lists.webkit.org/mailman/listinfo/webkit-changes