26336. a=jar, r=norris,pollman. We now allow uri creation failure to pass through to the webshell so we can throw error dialogs if need be. This allows 'https not supported' dialogs to be thrown from form submissions when https isn't installed
git-svn-id: svn://10.0.0.236/trunk@61885 18797224-902f-48f8-a5cc-f745e15eee43
This commit is contained in:
parent
a3d96716a1
commit
d251a79517
@ -742,16 +742,16 @@ nsFormFrame::OnSubmit(nsIPresContext* aPresContext, nsIFrame* aFrame)
|
||||
NS_WITH_SERVICE(nsIScriptSecurityManager, securityManager,
|
||||
NS_SCRIPTSECURITYMANAGER_PROGID, &result);
|
||||
nsCOMPtr<nsIURI> actionURL;
|
||||
if (NS_FAILED(result) ||
|
||||
NS_FAILED(result = NS_NewURI(getter_AddRefs(actionURL), href, docURL)) ||
|
||||
NS_FAILED(result = securityManager->CheckLoadURI(docURL, actionURL,
|
||||
PR_FALSE)))
|
||||
{
|
||||
return result;
|
||||
if (NS_FAILED(result)) return result;
|
||||
|
||||
result = NS_NewURI(getter_AddRefs(actionURL), href, docURL);
|
||||
if (NS_SUCCEEDED(result)) {
|
||||
result = securityManager->CheckLoadURI(docURL, actionURL, PR_FALSE);
|
||||
if (NS_FAILED(result)) return result;
|
||||
}
|
||||
|
||||
nsXPIDLCString scheme;
|
||||
if (NS_FAILED(result = actionURL->GetScheme(getter_Copies(scheme))))
|
||||
if (actionURL && NS_FAILED(result = actionURL->GetScheme(getter_Copies(scheme))))
|
||||
return result;
|
||||
if (nsCRT::strcmp(scheme, "mailto") == 0) {
|
||||
PRBool enabled;
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user