Index: Source/core/html/track/TextTrackList.cpp |
diff --git a/Source/core/html/track/TextTrackList.cpp b/Source/core/html/track/TextTrackList.cpp |
index 15df7569e1aa15364a8051a1f69b4a4f54a180fe..0738c95e7bac2388d6d0068042ba734fc8a20251 100644 |
--- a/Source/core/html/track/TextTrackList.cpp |
+++ b/Source/core/html/track/TextTrackList.cpp |
@@ -47,9 +47,12 @@ TextTrackList::~TextTrackList() |
{ |
#if !ENABLE(OILPAN) |
ASSERT(!m_owner); |
-#endif |
+ |
+ // TextTrackList and m_asyncEventQueue always become unreachable |
+ // together. So TextTrackList and m_asyncEventQueue are destructed in the |
+ // same GC. We don't need to close it explicitly in Oilpan. |
m_asyncEventQueue->close(); |
haraken
2014/06/12 10:48:51
In non-oilpan builds, some destructors call close(
tkent
2014/06/12 23:50:12
I'd like to keep non-oilpan code.
|
-#if !ENABLE(OILPAN) |
+ |
for (unsigned i = 0; i < length(); ++i) { |
item(i)->setTrackList(0); |
} |
@@ -334,6 +337,7 @@ HTMLMediaElement* TextTrackList::owner() const |
void TextTrackList::trace(Visitor* visitor) |
{ |
visitor->trace(m_owner); |
+ visitor->trace(m_asyncEventQueue); |
visitor->trace(m_addTrackTracks); |
visitor->trace(m_elementTracks); |
visitor->trace(m_inbandTracks); |