Bug 1685421 - Part 2: Stop using NS_ERROR_DOM_HIERARCHY_REQUEST_ERR in nsINode; r=smaug

Differential Revision: https://phabricator.services.mozilla.com/D113344
This commit is contained in:
Edgar Chen
2021-06-02 13:43:39 +00:00
parent 8b357eac5b
commit 492d02e96b
40 changed files with 338 additions and 230 deletions

View File

@@ -1716,7 +1716,7 @@ void nsCSSFrameConstructor::CreateGeneratedContentItem(
// think that we're going from not being anonymous to being anonymous and
// do some extra work; setting the flag here avoids that.
content->SetFlags(NODE_IS_IN_NATIVE_ANONYMOUS_SUBTREE);
container->AppendChildTo(content, false);
container->AppendChildTo(content, false, IgnoreErrors());
if (auto* element = Element::FromNode(content)) {
// If we created any children elements, Servo needs to traverse them, but
// the root is already set up.