Title: [114850] branches/chromium/1025
- Revision
- 114850
- Author
- [email protected]
- Date
- 2012-04-21 16:52:24 -0700 (Sat, 21 Apr 2012)
Log Message
Merge 113670
BUG=117110
Review URL: https://chromiumcodereview.appspot.com/10166026
Modified Paths
Added Paths
Diff
Copied: branches/chromium/1025/LayoutTests/fast/dom/text-node-attach-crash-expected.txt (from rev 113670, trunk/LayoutTests/fast/dom/text-node-attach-crash-expected.txt) (0 => 114850)
--- branches/chromium/1025/LayoutTests/fast/dom/text-node-attach-crash-expected.txt (rev 0)
+++ branches/chromium/1025/LayoutTests/fast/dom/text-node-attach-crash-expected.txt 2012-04-21 23:52:24 UTC (rev 114850)
@@ -0,0 +1 @@
+Test passes if it does not crash.
Copied: branches/chromium/1025/LayoutTests/fast/dom/text-node-attach-crash.xhtml (from rev 113670, trunk/LayoutTests/fast/dom/text-node-attach-crash.xhtml) (0 => 114850)
--- branches/chromium/1025/LayoutTests/fast/dom/text-node-attach-crash.xhtml (rev 0)
+++ branches/chromium/1025/LayoutTests/fast/dom/text-node-attach-crash.xhtml 2012-04-21 23:52:24 UTC (rev 114850)
@@ -0,0 +1,14 @@
+<html xmlns="http://www.w3.org/1999/xhtml">
+Test passes if it does not crash.
+<style></style>
+<script>
+if (window.layoutTestController)
+ layoutTestController.dumpAsText();
+
+var docElement = document.documentElement;
+document.removeChild(docElement);
+window._onload_ = function() {
+ document.appendChild(docElement);
+};
+</script>
+</html>
Modified: branches/chromium/1025/Source/WebCore/xml/parser/XMLDocumentParser.cpp (114849 => 114850)
--- branches/chromium/1025/Source/WebCore/xml/parser/XMLDocumentParser.cpp 2012-04-21 23:19:00 UTC (rev 114849)
+++ branches/chromium/1025/Source/WebCore/xml/parser/XMLDocumentParser.cpp 2012-04-21 23:52:24 UTC (rev 114850)
@@ -175,7 +175,8 @@
m_bufferedText.swap(empty);
#endif
- if (m_view && !m_leafTextNode->attached())
+ if (m_view && m_leafTextNode->parentNode() && m_leafTextNode->parentNode()->attached()
+ && !m_leafTextNode->attached())
m_leafTextNode->attach();
m_leafTextNode = 0;
_______________________________________________
webkit-changes mailing list
[email protected]
http://lists.webkit.org/mailman/listinfo.cgi/webkit-changes