Bug 1337622 - Temporarily fall back to SystemPrincipal if History entry does not have a valid triggeringPrincipal

This commit is contained in:
janekptacijarabaci 2018-04-30 23:06:51 +02:00 committed by Roy Tam
commit 55c354f1c0

View file

@ -12664,7 +12664,7 @@ nsDocShell::LoadHistoryEntry(nsISHEntry* aEntry, uint32_t aLoadType)
MOZ_ASSERT(triggeringPrincipal,
"need a valid triggeringPrincipal to load from history");
if (!triggeringPrincipal) {
return NS_ERROR_FAILURE;
triggeringPrincipal = nsContentUtils::GetSystemPrincipal();
}
// Passing nullptr as aSourceDocShell gives the same behaviour as before