Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(682)

Unified Diff: Source/core/dom/Node.cpp

Issue 106503002: Let Node.textContent never throw (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Created 7 years ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « Source/core/dom/Node.h ('k') | Source/core/dom/Node.idl » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/core/dom/Node.cpp
diff --git a/Source/core/dom/Node.cpp b/Source/core/dom/Node.cpp
index 94741dff039df0b906b5b83eed1c5bfcef13f195..725838c1c17584f36ae1f8e06acd69724aaa7c4e 100644
--- a/Source/core/dom/Node.cpp
+++ b/Source/core/dom/Node.cpp
@@ -1594,7 +1594,7 @@ String Node::textContent(bool convertBRsToNewlines) const
return isNullString ? String() : content.toString();
}
-void Node::setTextContent(const String& text, ExceptionState& exceptionState)
+void Node::setTextContent(const String& text)
{
switch (nodeType()) {
case TEXT_NODE:
@@ -1611,7 +1611,7 @@ void Node::setTextContent(const String& text, ExceptionState& exceptionState)
ChildListMutationScope mutation(*this);
container->removeChildren();
if (!text.isEmpty())
- container->appendChild(document().createTextNode(text), exceptionState);
+ container->appendChild(document().createTextNode(text), ASSERT_NO_EXCEPTION);
return;
}
case DOCUMENT_NODE:
« no previous file with comments | « Source/core/dom/Node.h ('k') | Source/core/dom/Node.idl » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698