Backed out changeset 05fceb07f800 (bug 1909698) for causing wpt crashes/assertions. CLOSED TREE

This commit is contained in:
Iulian Moraru
2024-09-16 23:28:38 +03:00
parent 39f742bf8e
commit 7b1382ec19
3 changed files with 1 additions and 49 deletions

View File

@@ -1329,20 +1329,7 @@ void nsDocShell::FirePageHideShowNonRecursive(bool aShow) {
mEODForCurrentDocument = false;
mIsRestoringDocument = true;
mLoadGroup->AddRequest(channel, nullptr);
nsCOMPtr<nsIURI> uri;
if (doc->FragmentDirective()) {
// If we have fragment directives, then we've mutated the document
// uri. Set the current URI from session history instead.
if (mozilla::SessionHistoryInParent()) {
uri = mActiveEntry->GetURI();
} else if (mOSHE) {
uri = mOSHE->GetURI();
}
}
if (!uri) {
uri = doc->GetDocumentURI();
}
SetCurrentURI(uri, channel,
SetCurrentURI(doc->GetDocumentURI(), channel,
/* aFireOnLocationChange */ true,
/* aIsInitialAboutBlank */ false,
/* aLocationFlags */ 0);