Bug 437723. Make sure to look at the nested innermost URI when looking for the origin. r+sr=sicking

This commit is contained in:
Boris Zbarsky 2008-07-28 23:10:05 -07:00
parent 09d4442e30
commit f61641d25e

View File

@ -1044,7 +1044,9 @@ GetPrincipalDomainOrigin(nsIPrincipal* aPrincipal,
if (!uri) {
aPrincipal->GetURI(getter_AddRefs(uri));
}
NS_ENSURE_TRUE(uri, NS_ERROR_UNEXPECTED);
uri = NS_GetInnermostURI(uri);
NS_ENSURE_TRUE(uri, NS_ERROR_UNEXPECTED);
nsCAutoString hostPort;