Chromium Code Reviews| Index: Source/core/dom/shadow/ElementShadow.cpp |
| diff --git a/Source/core/dom/shadow/ElementShadow.cpp b/Source/core/dom/shadow/ElementShadow.cpp |
| index 8be13446f18645649efdd25a428a4ea025891357..e8ddc164f940ed5ef9999151a2fd21dce3ad2ba1 100644 |
| --- a/Source/core/dom/shadow/ElementShadow.cpp |
| +++ b/Source/core/dom/shadow/ElementShadow.cpp |
| @@ -122,9 +122,9 @@ inline void DistributionPool::detachNonDistributedNodes() |
| } |
| } |
| -PassOwnPtr<ElementShadow> ElementShadow::create() |
| +PassOwnPtrWillBeRawPtr<ElementShadow> ElementShadow::create() |
| { |
| - return adoptPtr(new ElementShadow()); |
| + return adoptPtrWillBeNoop(new ElementShadow()); |
| } |
| ElementShadow::ElementShadow() |
| @@ -165,6 +165,9 @@ ShadowRoot& ElementShadow::addShadowRoot(Element& shadowHost, ShadowRoot::Shadow |
| void ElementShadow::removeDetachedShadowRoots() |
| { |
| + // With Oilpan, the Element shadow roots may have been finalized |
| + // during the same sweep. Do not access, but do the minimum |
| + // necessary/allowed, just clearing the list of roots. |
|
haraken
2014/05/07 02:10:26
ElementShadow::removeDetachedShadowRoots() is not
sof
2014/05/07 07:01:01
Will remove comment.
|
| // Dont protect this ref count. |
| Element* shadowHost = host(); |
| ASSERT(shadowHost); |
| @@ -178,7 +181,6 @@ void ElementShadow::removeDetachedShadowRoots() |
| oldRoot->setPrev(0); |
| oldRoot->setNext(0); |
| } |
| - |
| } |
| void ElementShadow::attach(const Node::AttachContext& context) |