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

Unified Diff: Source/modules/serviceworkers/ServiceWorkerRegistration.h

Issue 874003002: Oilpan: dispose ServiceWorker (and registration) objects earlier. (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: tidying Created 5 years, 11 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
Index: Source/modules/serviceworkers/ServiceWorkerRegistration.h
diff --git a/Source/modules/serviceworkers/ServiceWorkerRegistration.h b/Source/modules/serviceworkers/ServiceWorkerRegistration.h
index 0cf67c255bc50426162cca7b14412622f83f4327..62ae742a0514c5ad5170ce7b04ffdb612851688d 100644
--- a/Source/modules/serviceworkers/ServiceWorkerRegistration.h
+++ b/Source/modules/serviceworkers/ServiceWorkerRegistration.h
@@ -31,6 +31,7 @@ class ServiceWorkerRegistration final
DEFINE_WRAPPERTYPEINFO();
DEFINE_EVENT_TARGET_REFCOUNTING_WILL_BE_REMOVED(RefCountedGarbageCollected<ServiceWorkerRegistration>);
USING_GARBAGE_COLLECTED_MIXIN(ServiceWorkerRegistration);
+ USING_PRE_FINALIZER(ServiceWorkerRegistration, dispose);
public:
// EventTarget overrides.
virtual const AtomicString& interfaceName() const override;
@@ -60,6 +61,7 @@ public:
DEFINE_ATTRIBUTE_EVENT_LISTENER(updatefound);
+ virtual ~ServiceWorkerRegistration() override;
virtual void trace(Visitor*) override;
private:
@@ -70,6 +72,8 @@ private:
virtual bool hasPendingActivity() const override;
virtual void stop() override;
+ void dispose();
+
OwnPtr<WebServiceWorkerRegistration> m_outerRegistration;
WebServiceWorkerProvider* m_provider;
RefPtrWillBeMember<ServiceWorker> m_installing;
« no previous file with comments | « Source/modules/serviceworkers/ServiceWorker.cpp ('k') | Source/modules/serviceworkers/ServiceWorkerRegistration.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698