Index: Source/core/html/HTMLDetailsElement.cpp |
diff --git a/Source/core/html/HTMLDetailsElement.cpp b/Source/core/html/HTMLDetailsElement.cpp |
index b0ee16b0373e21db3643fe10996b74cc64a81048..80aaba8841ee8f5594a88c3703150ad40592f1b7 100644 |
--- a/Source/core/html/HTMLDetailsElement.cpp |
+++ b/Source/core/html/HTMLDetailsElement.cpp |
@@ -54,7 +54,7 @@ RenderObject* HTMLDetailsElement::createRenderer(RenderStyle*) |
return new RenderBlockFlow(this); |
} |
-void HTMLDetailsElement::didAddUserAgentShadowRoot(ShadowRoot* root) |
+void HTMLDetailsElement::didAddUserAgentShadowRoot(ShadowRoot& root) |
{ |
DEFINE_STATIC_LOCAL(AtomicString, summarySelector, ("summary:first-of-type", AtomicString::ConstructFromLiteral)); |
@@ -65,8 +65,8 @@ void HTMLDetailsElement::didAddUserAgentShadowRoot(ShadowRoot* root) |
content->setAttribute(selectAttr, summarySelector); |
content->appendChild(defaultSummary); |
- root->appendChild(content); |
- root->appendChild(HTMLContentElement::create(document())); |
+ root.appendChild(content.release()); |
+ root.appendChild(HTMLContentElement::create(document())); |
} |
Element* HTMLDetailsElement::findMainSummary() const |