Bug 1725680, requested index should be used only by the nsSHistory (and related code in CanonicalBrowsingContext), r=peterv
Using requestedIndex on the child side is hard, because there are race conditions when a session history load is triggered and at the same time a non-session history load commits a new active entry. Differential Revision: https://phabricator.services.mozilla.com/D126619
This commit is contained in:
@@ -3426,10 +3426,8 @@ void BrowsingContext::SessionHistoryCommit(
|
||||
changeID = rootSH->AddPendingHistoryChange();
|
||||
}
|
||||
} else {
|
||||
// This is a load from session history, so we can update
|
||||
// index and length immediately.
|
||||
rootSH->SetIndexAndLength(aInfo.mRequestedIndex,
|
||||
aInfo.mSessionHistoryLength, changeID);
|
||||
// History load doesn't change the length, only index.
|
||||
changeID = rootSH->AddPendingHistoryChange(aInfo.mOffset, 0);
|
||||
}
|
||||
}
|
||||
ContentChild* cc = ContentChild::GetSingleton();
|
||||
|
||||
Reference in New Issue
Block a user