Index: Source/core/rendering/RenderBlock.cpp |
diff --git a/Source/core/rendering/RenderBlock.cpp b/Source/core/rendering/RenderBlock.cpp |
index 7a4db09eda33c4fdc5d87bc6e6582270b9c086ae..fb4dd16de83b758328d9a3be7075a17a4c9e7fa3 100644 |
--- a/Source/core/rendering/RenderBlock.cpp |
+++ b/Source/core/rendering/RenderBlock.cpp |
@@ -216,7 +216,7 @@ static void appendImagesFromStyle(Vector<ImageResource*>& images, RenderStyle& b |
appendImageIfNotNull(images, blockStyle.shapeOutside()->image()); |
} |
-RenderBlock::~RenderBlock() |
+void RenderBlock::removeFromGlobalMaps() |
{ |
if (hasColumns()) |
gColumnInfoMap->take(this); |
@@ -226,6 +226,22 @@ RenderBlock::~RenderBlock() |
removeBlockFromDescendantAndContainerMaps(this, gPositionedDescendantsMap, gPositionedContainerMap); |
} |
+RenderBlock::~RenderBlock() |
+{ |
+#if !ENABLE(OILPAN) |
+ removeFromGlobalMaps(); |
haraken
2014/08/12 08:08:15
Can't we call removeFromGlobalMaps() in destroy()
tkent
2014/08/12 08:37:51
We can't. |this| is deleted in destroy().
|
+#endif |
+} |
+ |
+void RenderBlock::destroy() |
+{ |
+ RenderBox::destroy(); |
haraken
2014/08/12 08:08:15
Nit: Make the destroy call to the parent class a t
tkent
2014/08/12 08:37:51
We can't do it. destroy() depends on the global m
haraken
2014/08/12 08:47:00
I understand what's going on. Then it seems to me
|
+#if ENABLE(OILPAN) |
+ // RenderObject::removeChild called in destory() depends on gColumnInfoMap. |
+ removeFromGlobalMaps(); |
+#endif |
+} |
+ |
void RenderBlock::willBeDestroyed() |
{ |
// Mark as being destroyed to avoid trouble with merges in removeChild(). |