Fix crash in nsCodebasePrincipal::Equals when browser.registration.enable is set to true.
r=racham git-svn-id: svn://10.0.0.236/trunk@59687 18797224-902f-48f8-a5cc-f745e15eee43
This commit is contained in:
@@ -75,6 +75,10 @@ nsCertificatePrincipal::Equals(nsIPrincipal * other, PRBool * result)
|
||||
*result = PR_TRUE;
|
||||
return NS_OK;
|
||||
}
|
||||
if (!other) {
|
||||
*result = PR_FALSE;
|
||||
return NS_OK;
|
||||
}
|
||||
nsresult rv;
|
||||
nsCOMPtr<nsICertificatePrincipal> otherCertificate =
|
||||
do_QueryInterface(other, &rv);
|
||||
|
||||
@@ -72,6 +72,10 @@ nsCodebasePrincipal::Equals(nsIPrincipal *other, PRBool *result)
|
||||
*result = PR_TRUE;
|
||||
return NS_OK;
|
||||
}
|
||||
if (!other) {
|
||||
*result = PR_FALSE;
|
||||
return NS_OK;
|
||||
}
|
||||
nsCOMPtr<nsICodebasePrincipal> otherCodebase;
|
||||
if (NS_FAILED(other->QueryInterface(
|
||||
NS_GET_IID(nsICodebasePrincipal),
|
||||
|
||||
Reference in New Issue
Block a user