[SCM] WebKit Debian packaging branch, debian/experimental, updated. upstream/1.3.3-9427-gc2be6fc
abarth at webkit.org
abarth at webkit.org
Wed Dec 22 15:23:45 UTC 2010
The following commit has been merged in the debian/experimental branch:
commit da68b9988b429c1152b944a4f79f2287924ea269
Author: abarth at webkit.org <abarth at webkit.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Date: Tue Nov 2 19:15:19 2010 +0000
2010-11-02 Adam Barth <abarth at webkit.org>
Reviewed by Eric Seidel.
querySelectorAll('body>:last-child') does not work unless HTML file ends with 'new-line'.
https://bugs.webkit.org/show_bug.cgi?id=47166
We need to pop all the open elements when we end the document in the
AfterAfterBody state.
Test: fast/parser/pop-all-after-after-body.html
* html/parser/HTMLTreeBuilder.cpp:
(WebCore::HTMLTreeBuilder::processEndOfFile):
2010-11-02 Adam Barth <abarth at webkit.org>
Reviewed by Eric Seidel.
querySelectorAll('body>:last-child') does not work unless HTML file ends with 'new-line'.
https://bugs.webkit.org/show_bug.cgi?id=47166
Test that :last-child works when we end the document in the
AfterAfterBody state.
* fast/parser/pop-all-after-after-body-expected.txt: Added.
* fast/parser/pop-all-after-after-body.html: Added.
git-svn-id: http://svn.webkit.org/repository/webkit/trunk@71147 268f45cc-cd09-0410-ab3c-d52691b4dbfc
diff --git a/LayoutTests/ChangeLog b/LayoutTests/ChangeLog
index 83658cb..c53b369 100644
--- a/LayoutTests/ChangeLog
+++ b/LayoutTests/ChangeLog
@@ -1,3 +1,16 @@
+2010-11-02 Adam Barth <abarth at webkit.org>
+
+ Reviewed by Eric Seidel.
+
+ querySelectorAll('body>:last-child') does not work unless HTML file ends with 'new-line'.
+ https://bugs.webkit.org/show_bug.cgi?id=47166
+
+ Test that :last-child works when we end the document in the
+ AfterAfterBody state.
+
+ * fast/parser/pop-all-after-after-body-expected.txt: Added.
+ * fast/parser/pop-all-after-after-body.html: Added.
+
2010-11-02 Adele Peterson <adele at apple.com>
Reviewed by Kent Tamura.
diff --git a/LayoutTests/fast/parser/pop-all-after-after-body-expected.txt b/LayoutTests/fast/parser/pop-all-after-after-body-expected.txt
new file mode 100644
index 0000000..8b02bb8
--- /dev/null
+++ b/LayoutTests/fast/parser/pop-all-after-after-body-expected.txt
@@ -0,0 +1,2 @@
+ALERT: PASS
+last
diff --git a/LayoutTests/fast/parser/pop-all-after-after-body.html b/LayoutTests/fast/parser/pop-all-after-after-body.html
new file mode 100644
index 0000000..3ea1910
--- /dev/null
+++ b/LayoutTests/fast/parser/pop-all-after-after-body.html
@@ -0,0 +1,21 @@
+<!DOCTYPE html>
+<html>
+ <head>
+ <meta http-equiv="content-type" content="text/html; charset=utf-8" />
+ <title>last-child test</title>
+ <script>
+ if (window.layoutTestController)
+ layoutTestController.dumpAsText();
+
+ window.onload = function() {
+ // Notice that this file lacks a terminating newline character!
+ // That's essential to what this test is testing!
+ if (document.querySelectorAll('body>:last-child').length == 1) {
+ alert('PASS');
+ } else {
+ alert('FAIL');
+ }
+ }
+ </script>
+ </head>
+ <body><div id='last'>last</div></body></html>
\ No newline at end of file
diff --git a/WebCore/ChangeLog b/WebCore/ChangeLog
index 8cc8d64..402130a 100644
--- a/WebCore/ChangeLog
+++ b/WebCore/ChangeLog
@@ -1,3 +1,18 @@
+2010-11-02 Adam Barth <abarth at webkit.org>
+
+ Reviewed by Eric Seidel.
+
+ querySelectorAll('body>:last-child') does not work unless HTML file ends with 'new-line'.
+ https://bugs.webkit.org/show_bug.cgi?id=47166
+
+ We need to pop all the open elements when we end the document in the
+ AfterAfterBody state.
+
+ Test: fast/parser/pop-all-after-after-body.html
+
+ * html/parser/HTMLTreeBuilder.cpp:
+ (WebCore::HTMLTreeBuilder::processEndOfFile):
+
2010-11-02 Patrick Gansterer <paroga at webkit.org>
Reviewed by Adam Roben.
diff --git a/WebCore/html/parser/HTMLTreeBuilder.cpp b/WebCore/html/parser/HTMLTreeBuilder.cpp
index 310ff60..c385437 100644
--- a/WebCore/html/parser/HTMLTreeBuilder.cpp
+++ b/WebCore/html/parser/HTMLTreeBuilder.cpp
@@ -2580,7 +2580,7 @@ void HTMLTreeBuilder::processEndOfFile(AtomicHTMLToken& token)
case AfterBodyMode:
case AfterAfterBodyMode:
ASSERT(insertionMode() == AfterBodyMode || insertionMode() == AfterAfterBodyMode);
- return;
+ break;
case InHeadNoscriptMode:
ASSERT(insertionMode() == InHeadNoscriptMode);
defaultForInHeadNoscript();
@@ -2602,11 +2602,11 @@ void HTMLTreeBuilder::processEndOfFile(AtomicHTMLToken& token)
case InColumnGroupMode:
if (m_tree.currentElement() == m_tree.openElements()->htmlElement()) {
ASSERT(isParsingFragment());
- return;
+ return; // FIXME: Should we break here instead of returning?
}
if (!processColgroupEndTagForInColumnGroup()) {
ASSERT(isParsingFragment());
- return;
+ return; // FIXME: Should we break here instead of returning?
}
prepareToReprocessToken();
processEndOfFile(token);
--
WebKit Debian packaging
More information about the Pkg-webkit-commits
mailing list