mirror of
https://repo.dactyloidae.xyz/Dactyloidae/UXP.git
synced 2026-10-25 08:37:30 +09:00
backport mozbug 1350090: Turn off the spammy warning that goes off every time we create an about:blank content viewer; r=mystor
During a debug session, log spam appears because we are trying to get the origin out of a principal for about:blank, which will throw, which is expected.
This commit is contained in:
parent
fb3d16e2db
commit
fdec621f51
1 changed files with 5 additions and 1 deletions
|
|
@ -107,7 +107,11 @@ nsresult
|
||||||
GetOriginFromPrincipal(nsIPrincipal* aPrincipal, nsACString& aOrigin)
|
GetOriginFromPrincipal(nsIPrincipal* aPrincipal, nsACString& aOrigin)
|
||||||
{
|
{
|
||||||
nsresult rv = aPrincipal->GetOriginNoSuffix(aOrigin);
|
nsresult rv = aPrincipal->GetOriginNoSuffix(aOrigin);
|
||||||
NS_ENSURE_SUCCESS(rv, rv);
|
// The principal may belong to the about:blank content viewer, so this can be
|
||||||
|
// expected to fail.
|
||||||
|
if (NS_FAILED(rv)) {
|
||||||
|
return rv;
|
||||||
|
}
|
||||||
|
|
||||||
nsAutoCString suffix;
|
nsAutoCString suffix;
|
||||||
rv = aPrincipal->GetOriginSuffix(suffix);
|
rv = aPrincipal->GetOriginSuffix(suffix);
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue