Title: [143335] trunk/Source/WebKit2
Revision
143335
Author
abe...@webkit.org
Date
2013-02-19 08:26:25 -0800 (Tue, 19 Feb 2013)

Log Message

[Qt][WK2] ASSERT(node) hit in WebPage::findZoomableAreaForPoint if no zoomable area found
https://bugs.webkit.org/show_bug.cgi?id=110220

Reviewed by Allan Sandfeld Jensen.

If EventHandler::bestZoomableAreaForTouchPoint was unsuccessfull, eg.
no node was found for a given point, we hit ASSERT(node).
We should only assert for a valid node if a zoomable area was found.

* WebProcess/WebPage/WebPage.cpp:
(WebKit::WebPage::findZoomableAreaForPoint):

Modified Paths

Diff

Modified: trunk/Source/WebKit2/ChangeLog (143334 => 143335)


--- trunk/Source/WebKit2/ChangeLog	2013-02-19 16:12:47 UTC (rev 143334)
+++ trunk/Source/WebKit2/ChangeLog	2013-02-19 16:26:25 UTC (rev 143335)
@@ -1,3 +1,17 @@
+2013-02-19  Andras Becsi  <andras.be...@digia.com>
+
+        [Qt][WK2] ASSERT(node) hit in WebPage::findZoomableAreaForPoint if no zoomable area found
+        https://bugs.webkit.org/show_bug.cgi?id=110220
+
+        Reviewed by Allan Sandfeld Jensen.
+
+        If EventHandler::bestZoomableAreaForTouchPoint was unsuccessfull, eg.
+        no node was found for a given point, we hit ASSERT(node).
+        We should only assert for a valid node if a zoomable area was found.
+
+        * WebProcess/WebPage/WebPage.cpp:
+        (WebKit::WebPage::findZoomableAreaForPoint):
+
 2013-02-19  Christophe Dumez  <ch.du...@sisa.samsung.com>
 
         Regression(r143273): Caused a lot of tests to time out

Modified: trunk/Source/WebKit2/WebProcess/WebPage/WebPage.cpp (143334 => 143335)


--- trunk/Source/WebKit2/WebProcess/WebPage/WebPage.cpp	2013-02-19 16:12:47 UTC (rev 143334)
+++ trunk/Source/WebKit2/WebProcess/WebPage/WebPage.cpp	2013-02-19 16:26:25 UTC (rev 143335)
@@ -3015,11 +3015,12 @@
     Node* node = 0;
     IntRect zoomableArea;
     bool foundAreaForTouchPoint = m_mainFrame->coreFrame()->eventHandler()->bestZoomableAreaForTouchPoint(point, IntSize(area.width() / 2, area.height() / 2), zoomableArea, node);
-    ASSERT(node);
 
     if (!foundAreaForTouchPoint)
         return;
 
+    ASSERT(node);
+
     if (node->document() && node->document()->view())
         zoomableArea = node->document()->view()->contentsToWindow(zoomableArea);
 
_______________________________________________
webkit-changes mailing list
webkit-changes@lists.webkit.org
https://lists.webkit.org/mailman/listinfo/webkit-changes

Reply via email to