mirror of
https://repo.dactyloidae.xyz/Dactyloidae/UXP.git
synced 2026-08-26 01:08:39 +09:00
Bug 1359204 - Use SystemPrincipal as TriggeringPrincipal when loading page as view-source
This commit is contained in:
parent
69c0760b8b
commit
e31712c143
1 changed files with 5 additions and 0 deletions
|
|
@ -5689,6 +5689,11 @@ nsDocShell::LoadPage(nsISupports* aPageDescriptor, uint32_t aDisplayType)
|
|||
}
|
||||
shEntry->SetURI(newUri);
|
||||
shEntry->SetOriginalURI(nullptr);
|
||||
// shEntry's current triggering principal is whoever loaded that page initially.
|
||||
// But now we're doing another load of the page, via an API that is only exposed
|
||||
// to system code. The triggering principal for this load should be the system
|
||||
// principal.
|
||||
shEntry->SetTriggeringPrincipal(nsContentUtils::GetSystemPrincipal());
|
||||
}
|
||||
|
||||
rv = LoadHistoryEntry(shEntry, LOAD_HISTORY);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue