Bug 1744025: Use CheckedUnsafePtr<WorkerPrivate> in WorkerEventTarget. r=dom-worker-reviewers,edenchuang

Depends on D132799

Differential Revision: https://phabricator.services.mozilla.com/D132800
This commit is contained in:
Jens Stutte 2022-01-25 08:53:02 +00:00
parent b7adbf2325
commit dcae57ea85

View File

@ -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<WorkerPrivate> mWorkerPrivate;
const Behavior mBehavior;
~WorkerEventTarget() = default;