From 4f7e431137caffc0c1cc8deee361893a7eabe70c Mon Sep 17 00:00:00 2001 From: wolfbeast Date: Tue, 11 Dec 2018 23:17:50 +0100 Subject: Clear weak pointers in VTT shutdown observers. --- dom/html/TextTrackManager.h | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) (limited to 'dom/html/TextTrackManager.h') diff --git a/dom/html/TextTrackManager.h b/dom/html/TextTrackManager.h index d20707346..4ad1a57a7 100644 --- a/dom/html/TextTrackManager.h +++ b/dom/html/TextTrackManager.h @@ -170,11 +170,15 @@ private: { MOZ_ASSERT(NS_IsMainThread()); if (strcmp(aTopic, NS_XPCOM_SHUTDOWN_OBSERVER_ID) == 0) { - nsContentUtils::UnregisterShutdownObserver(this); - mManager->NotifyShutdown(); + if (mManager) { + mManager->NotifyShutdown(); + } + Unregister(); } return NS_OK; } + + void Unregister(); private: ~ShutdownObserverProxy() {}; -- cgit v1.2.3 From 5335681cd2ab05ad47e81be7722c9eee19d54065 Mon Sep 17 00:00:00 2001 From: adeshkp Date: Sat, 12 Jan 2019 06:20:31 -0500 Subject: Telemetry: Remove stubs and related code --- dom/html/TextTrackManager.h | 7 ------- 1 file changed, 7 deletions(-) (limited to 'dom/html/TextTrackManager.h') diff --git a/dom/html/TextTrackManager.h b/dom/html/TextTrackManager.h index 4ad1a57a7..2375aa4bb 100644 --- a/dom/html/TextTrackManager.h +++ b/dom/html/TextTrackManager.h @@ -148,13 +148,6 @@ private: nsTArray& aTextTracks); bool TrackIsDefault(TextTrack* aTextTrack); - void ReportTelemetryForTrack(TextTrack* aTextTrack) const; - void ReportTelemetryForCue(); - - // If there is at least one cue has been added to the cue list once, we would - // report the usage of cue to Telemetry. - bool mCueTelemetryReported; - class ShutdownObserverProxy final : public nsIObserver { NS_DECL_ISUPPORTS -- cgit v1.2.3