зеркало из https://github.com/mozilla/gecko-dev.git
Bug 1539959 - Don't send WindowGlobalChild constructors when parent BrowsingContext has already been closed, r=farre
Differential Revision: https://phabricator.services.mozilla.com/D27365 --HG-- extra : moz-landing-system : lando
This commit is contained in:
Родитель
04b89bc9c8
Коммит
48a4697754
|
@ -60,6 +60,13 @@ already_AddRefed<WindowGlobalChild> WindowGlobalChild::Create(
|
|||
|
||||
RefPtr<WindowGlobalChild> wgc = new WindowGlobalChild(aWindow, bc);
|
||||
|
||||
// If we have already closed our browsing context, return a pre-closed
|
||||
// WindowGlobalChild actor.
|
||||
if (bc->GetClosed()) {
|
||||
wgc->ActorDestroy(FailedConstructor);
|
||||
return wgc.forget();
|
||||
}
|
||||
|
||||
WindowGlobalInit init(principal, aWindow->GetDocumentURI(), bc,
|
||||
wgc->mInnerWindowId, wgc->mOuterWindowId);
|
||||
|
||||
|
|
Загрузка…
Ссылка в новой задаче