[XForms] Allow chrome:// to submit anywhere. Bug 316931, r=doronr+aaronr, patch by surkov@dc.baikal.ru

git-svn-id: svn://10.0.0.236/trunk@185258 18797224-902f-48f8-a5cc-f745e15eee43
This commit is contained in:
allan%beaufour.dk 2005-11-24 14:24:15 +00:00
parent 45b9228e04
commit affd140dfe

View File

@ -965,9 +965,13 @@ nsXFormsSubmissionElement::CheckSameOrigin(nsIURI *aBaseURI, nsIURI *aTestURI)
// if same origin is required, default to false
allowSubmission = PR_FALSE;
// if we don't replace the instance, we allow file:// to submit data anywhere
// if we don't replace the instance, we allow file:// and chrome://
// to submit data anywhere
if (!mIsReplaceInstance) {
aBaseURI->SchemeIs("file", &allowSubmission);
if (!allowSubmission) {
aBaseURI->SchemeIs("chrome", &allowSubmission);
}
}
// let's check the permission manager