Bug 1646996 - Proxy to main thread in ~DocGroup. r=smaug
When destroying the DocGroup, it will most certainly have no documents attached to it, which makes labelling them a strange thing to do. And the event target in DocGroup would most certainly dispatch to release on the main thread anyway, so switch to do that right away. Differential Revision: https://phabricator.services.mozilla.com/D88538
This commit is contained in:
@@ -186,11 +186,10 @@ DocGroup::~DocGroup() {
|
||||
MOZ_RELEASE_ASSERT(!mBrowsingContextGroup);
|
||||
|
||||
if (!NS_IsMainThread()) {
|
||||
nsIEventTarget* target = EventTargetFor(TaskCategory::Other);
|
||||
NS_ProxyRelease("DocGroup::mReactionsStack", target,
|
||||
mReactionsStack.forget());
|
||||
NS_ReleaseOnMainThread("DocGroup::mReactionsStack",
|
||||
mReactionsStack.forget());
|
||||
|
||||
NS_ProxyRelease("DocGroup::mArena", target, mArena.forget());
|
||||
NS_ReleaseOnMainThread("DocGroup::mArena", mArena.forget());
|
||||
}
|
||||
|
||||
if (mIframePostMessageQueue) {
|
||||
|
||||
Reference in New Issue
Block a user