Bug 1453567 - Null-check rootSH in nsDocShell::AddState. r=bz, a=RyanVM
Looks like this accidentally got thrown out in the refactoring.
This commit is contained in:
@@ -11854,6 +11854,8 @@ nsDocShell::AddState(JS::Handle<JS::Value> aData, const nsAString& aTitle,
|
||||
// call ReplaceEntry so that we notify nsIHistoryListeners that an entry
|
||||
// was replaced.
|
||||
RefPtr<ChildSHistory> rootSH = GetRootSessionHistory();
|
||||
NS_ENSURE_TRUE(rootSH, NS_ERROR_UNEXPECTED);
|
||||
|
||||
if (!aReplace) {
|
||||
int32_t curIndex = rootSH->Index();
|
||||
if (curIndex > -1) {
|
||||
|
||||
Reference in New Issue
Block a user