Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(693)

Unified Diff: Source/core/loader/ImageLoader.cpp

Issue 1226373008: Oilpan: switch ImageLoader to be prefinalized. (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: compile fix Created 5 years, 5 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « Source/core/loader/ImageLoader.h ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/core/loader/ImageLoader.cpp
diff --git a/Source/core/loader/ImageLoader.cpp b/Source/core/loader/ImageLoader.cpp
index 9f80239030c44ff3c069cdab32c63a32bc1f6e54..14887644c1ce3d4d850b1ba6e71b9d6628aa4a06 100644
--- a/Source/core/loader/ImageLoader.cpp
+++ b/Source/core/loader/ImageLoader.cpp
@@ -148,10 +148,20 @@ ImageLoader::ImageLoader(Element* element)
, m_highPriorityClientCount(0)
{
WTF_LOG(Timers, "new ImageLoader %p", this);
+#if ENABLE(OILPAN)
+ ThreadState::current()->registerPreFinalizer(this);
+#endif
}
ImageLoader::~ImageLoader()
{
+#if !ENABLE(OILPAN)
+ dispose();
+#endif
+}
+
+void ImageLoader::dispose()
+{
WTF_LOG(Timers, "~ImageLoader %p; m_hasPendingLoadEvent=%d, m_hasPendingErrorEvent=%d",
this, m_hasPendingLoadEvent, m_hasPendingErrorEvent);
« no previous file with comments | « Source/core/loader/ImageLoader.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698