Bug 1382093 - Null check docShell in InternalSetDocShellIsActive, r=smaug

MozReview-Commit-ID: JHtmTSomFlb
This commit is contained in:
Michael Layzell 2017-07-25 11:35:39 -04:00
parent 7a24a5eff4
commit 6968a2e955

View File

@ -2462,6 +2462,10 @@ TabChild::InternalSetDocShellIsActive(bool aIsActive, bool aPreserveLayers)
if (aIsActive) {
MakeVisible();
if (!docShell) {
return;
}
// We don't use TabChildBase::GetPresShell() here because that would create
// a content viewer if one doesn't exist yet. Creating a content viewer can
// cause JS to run, which we want to avoid. nsIDocShell::GetPresShell