Be a little more careul with inheriting principals. Bug 304690, r=dveditz,

sr=jst
This commit is contained in:
bzbarsky%mit.edu 2007-04-27 04:01:17 +00:00
Родитель ed292adafe
Коммит e639b34fbe
1 изменённых файлов: 3 добавлений и 1 удалений

Просмотреть файл

@ -6370,7 +6370,9 @@ nsDocShell::InternalLoad(nsIURI * aURI,
//
{
PRBool inherits;
if (!owner && (aFlags & INTERNAL_LOAD_FLAGS_INHERIT_OWNER) &&
// One more twist: Don't inherit the owner for external loads.
if (aLoadType != LOAD_NORMAL_EXTERNAL && !owner &&
(aFlags & INTERNAL_LOAD_FLAGS_INHERIT_OWNER) &&
NS_SUCCEEDED(URIInheritsSecurityContext(aURI, &inherits)) &&
inherits) {
owner = GetInheritedPrincipal(PR_TRUE);