From dcae57ea85d9b22e19eaa365c694d71a08067349 Mon Sep 17 00:00:00 2001 From: Jens Stutte Date: Tue, 25 Jan 2022 08:53:02 +0000 Subject: [PATCH] Bug 1744025: Use CheckedUnsafePtr in WorkerEventTarget. r=dom-worker-reviewers,edenchuang Depends on D132799 Differential Revision: https://phabricator.services.mozilla.com/D132800 --- dom/workers/WorkerEventTarget.h | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/dom/workers/WorkerEventTarget.h b/dom/workers/WorkerEventTarget.h index 75af983df8e6..7260fb8b0ca3 100644 --- a/dom/workers/WorkerEventTarget.h +++ b/dom/workers/WorkerEventTarget.h @@ -9,12 +9,11 @@ #include "nsISerialEventTarget.h" #include "mozilla/Mutex.h" +#include "mozilla/dom/WorkerPrivate.h" namespace mozilla { namespace dom { -class WorkerPrivate; - class WorkerEventTarget final : public nsISerialEventTarget { public: // The WorkerEventTarget supports different dispatch behaviors: @@ -30,7 +29,7 @@ class WorkerEventTarget final : public nsISerialEventTarget { private: mozilla::Mutex mMutex; - WorkerPrivate* mWorkerPrivate; + CheckedUnsafePtr mWorkerPrivate; const Behavior mBehavior; ~WorkerEventTarget() = default;