Title: [181773] trunk
- Revision
- 181773
- Author
- [email protected]
- Date
- 2015-03-19 17:47:32 -0700 (Thu, 19 Mar 2015)
Log Message
Source/WebCore:
REGRESSION (r109593): Clicking after last inline element could cause a crash.
https://bugs.webkit.org/show_bug.cgi?id=142880
rdar://problem/17222294
Reviewed by Ryosuke Niwa.
Test: editing/selection/click-after-last-inline-crash.html
* rendering/RootInlineBox.cpp:
(WebCore::RootInlineBox::closestLeafChildForLogicalLeftPosition):
LayoutTests:
Web Inspector: Adopt ES6 Class Syntax for all Model Objects
https://bugs.webkit.org/show_bug.cgi?id=142858
Patch by Joseph Pecoraro <[email protected]> on 2015-03-19
Reviewed by Timothy Hatcher.
* inspector/model/parse-script-syntax-tree.html:
This test was calling a constructor without "new". Class
syntax enforces "new" and threw an exception.
Modified Paths
Added Paths
Diff
Modified: trunk/LayoutTests/ChangeLog (181772 => 181773)
--- trunk/LayoutTests/ChangeLog 2015-03-20 00:44:12 UTC (rev 181772)
+++ trunk/LayoutTests/ChangeLog 2015-03-20 00:47:32 UTC (rev 181773)
@@ -11,6 +11,17 @@
2015-03-19 Enrica Casucci <[email protected]>
+ REGRESSION (r109593): Clicking after last inline element could cause a crash.
+ https://bugs.webkit.org/show_bug.cgi?id=142880
+ rdar://problem/17222294
+
+ Reviewed by Ryosuke Niwa.
+
+ * editing/selection/click-after-last-inline-crash-expected.txt: Added.
+ * editing/selection/click-after-last-inline-crash.html: Added.
+
+2015-03-19 Enrica Casucci <[email protected]>
+
<attachment> should put URLs on the pasteboard so that Finder can accept drops.
https://bugs.webkit.org/show_bug.cgi?id=142801
rdar://problem/19982527
Added: trunk/LayoutTests/editing/selection/click-after-last-inline-crash-expected.txt (0 => 181773)
--- trunk/LayoutTests/editing/selection/click-after-last-inline-crash-expected.txt (rev 0)
+++ trunk/LayoutTests/editing/selection/click-after-last-inline-crash-expected.txt 2015-03-20 00:47:32 UTC (rev 181773)
@@ -0,0 +1,7 @@
+Click after the end of the line with link.
+
+This is a link
+
+It should NOT crash!
+
+PASS
Added: trunk/LayoutTests/editing/selection/click-after-last-inline-crash.html (0 => 181773)
--- trunk/LayoutTests/editing/selection/click-after-last-inline-crash.html (rev 0)
+++ trunk/LayoutTests/editing/selection/click-after-last-inline-crash.html 2015-03-20 00:47:32 UTC (rev 181773)
@@ -0,0 +1,23 @@
+<html>
+<body>
+<div style="border: solid red 2px;">
+Click after the end of the line with link.<br><br><a id='test' href="" is a link</a><wbr><br><br>It should NOT crash!<br><br>
+</div>
+</body>
+<script>
+if (window.testRunner) {
+ testRunner.dumpAsText();
+
+ if (!window.eventSender)
+ document.writeln('This test requires eventSender');
+ else {
+ var testElement = document.getElementById('test');
+ eventSender.mouseMoveTo(testElement.offsetLeft + testElement.offsetWidth + 50, testElement.offsetTop + 5);
+ eventSender.mouseDown();
+ eventSender.mouseUp();
+ document.writeln('PASS');
+ }
+}
+
+</script>
+</html>
Modified: trunk/Source/WebCore/ChangeLog (181772 => 181773)
--- trunk/Source/WebCore/ChangeLog 2015-03-20 00:44:12 UTC (rev 181772)
+++ trunk/Source/WebCore/ChangeLog 2015-03-20 00:47:32 UTC (rev 181773)
@@ -1,5 +1,18 @@
2015-03-19 Enrica Casucci <[email protected]>
+ REGRESSION (r109593): Clicking after last inline element could cause a crash.
+ https://bugs.webkit.org/show_bug.cgi?id=142880
+ rdar://problem/17222294
+
+ Reviewed by Ryosuke Niwa.
+
+ Test: editing/selection/click-after-last-inline-crash.html
+
+ * rendering/RootInlineBox.cpp:
+ (WebCore::RootInlineBox::closestLeafChildForLogicalLeftPosition):
+
+2015-03-19 Enrica Casucci <[email protected]>
+
One more build fix after r181760.
* page/EventHandler.cpp:
Modified: trunk/Source/WebCore/rendering/RootInlineBox.cpp (181772 => 181773)
--- trunk/Source/WebCore/rendering/RootInlineBox.cpp 2015-03-20 00:44:12 UTC (rev 181772)
+++ trunk/Source/WebCore/rendering/RootInlineBox.cpp 2015-03-20 00:47:32 UTC (rev 181773)
@@ -763,12 +763,12 @@
return firstLeaf;
// Avoid returning a list marker when possible.
- if (leftPosition <= firstLeaf->logicalLeft() && !firstLeaf->renderer().isListMarker() && (!onlyEditableLeaves || isEditableLeaf(firstLeaf)))
+ if (firstLeaf && leftPosition <= firstLeaf->logicalLeft() && !firstLeaf->renderer().isListMarker() && (!onlyEditableLeaves || isEditableLeaf(firstLeaf)))
// The leftPosition coordinate is less or equal to left edge of the firstLeaf.
// Return it.
return firstLeaf;
- if (leftPosition >= lastLeaf->logicalRight() && !lastLeaf->renderer().isListMarker() && (!onlyEditableLeaves || isEditableLeaf(lastLeaf)))
+ if (lastLeaf && leftPosition >= lastLeaf->logicalRight() && !lastLeaf->renderer().isListMarker() && (!onlyEditableLeaves || isEditableLeaf(lastLeaf)))
// The leftPosition coordinate is greater or equal to right edge of the lastLeaf.
// Return it.
return lastLeaf;
_______________________________________________
webkit-changes mailing list
[email protected]
https://lists.webkit.org/mailman/listinfo/webkit-changes