Closed Bug 433014 Opened 17 years ago Closed 16 years ago

XML templates don't load from file://

Categories

(Core :: XUL, defect)

defect
Not set
major

Tracking

()

RESOLVED FIXED

People

(Reporter: sigh, Assigned: enndeakin)

References

()

Details

(Keywords: fixed1.9.1)

Attachments

(2 files, 1 obsolete file)

User-Agent: Mozilla/5.0 (Macintosh; U; PPC Mac OS X 10.5; en-GB; rv:1.9b5) Gecko/2008032619 Firefox/3.0b5 Build Identifier: Mozilla/5.0 (Macintosh; U; PPC Mac OS X 10.5; en-GB; rv:1.9b5) Gecko/2008032619 Firefox/3.0b5 http://developer.mozilla.org/samples/xultemp/template-guide-ex32b.xul doesn't work when running from local disk with its RDF datafile local too (file://) Reproducible: Always Steps to Reproduce: 1.open http://developer.mozilla.org/samples/xultemp/template-guide-ex32b.xul 2.save to Desktop 3.open http://developer.mozilla.org/samples/xultemp/template-guide-streets.rdf 4. save to Desktop 5. open Desktop/template-guide-ex32b.xul from File->Open File... Actual Results: window frame but no content Expected Results: full tree contents as seen at http://developer.mozilla.org/samples/xultemp/template-guide-ex32b.xul
Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.9pre) Gecko/2008050918 Minefield/3.0pre 1) Just going to the first link doesn't work right away. I had to close the tab and then open the link again. 2) Your steps are wrong. The second file should be: http://developer.mozilla.org/samples/xultemp/people2.xml However, that doesn't work either. So, I guess I can confirm this, but that's in addition to it barely working when NOT at a file:// URI.
Dave - you are absolutely correct... its my error! I should have referred to the RDF-based example in set 1): http://developer.mozilla.org/samples/xultemp/template-guide-ex32.xul However, I can confirm that I ALSO see your described error when loading: http://developer.mozilla.org/samples/xultemp/template-guide-ex32b.xul - my FFb3 also takes two loads of this URL to succeed. Looks like we have TWO bugs here, folks
Quick search turns up bug 427551 for this.
Hmmm... bug 427551 is about inline vs http loaded XML, which is slightly different though related.
CCing a XUL templates guy. These seem to be a major issues, so any comments would be appreciated.
well smart :o) I've just done a regression against FF2.0.0.12 and http://developer.mozilla.org/samples/xultemp/template-guide-ex32.xul works perfectly when accessed via http://, file:// and chrome:// I'm still setting up the test-bed for checking this for chrome:// in FF3b5.
Status: UNCONFIRMED → NEW
Component: General → XP Toolkit/Widgets: XUL
Ever confirmed: true
OS: Mac OS X → All
Product: Firefox → Core
QA Contact: general → xptoolkit.xul
Hardware: Macintosh → All
Component: XP Toolkit/Widgets: XUL → XUL
QA Contact: xptoolkit.xul → xptoolkit.widgets
This patch does a better uri security check. bz suggests that queryprocessor::LoadDatasources should be doing this check, since redirects would need to be handled anyway. I'm not really convinced that its better to put the onus on requiring query processors to do all of these checks (which other implementors wouldn't understand how to do), than to have the builder do most of this work itself. I think we should just keep a CheckMayLoad check for compatibilty and add clearer api documentation.
Assignee: nobody → enndeakin
Status: NEW → ASSIGNED
Attached patch updated patchSplinter Review
This bug is actually preventing the crashtest in bug 441785 from even running.
Attachment #355428 - Attachment is obsolete: true
Attachment #376407 - Flags: superreview?(Olli.Pettay)
Attachment #376407 - Flags: review?(Olli.Pettay)
Comment on attachment 376407 [details] [diff] [review] updated patch Looks reasonable, but please add testcases. Both for successful and failing cases.
Attachment #376407 - Flags: superreview?(Olli.Pettay)
Attachment #376407 - Flags: superreview+
Attachment #376407 - Flags: review?(Olli.Pettay)
Attachment #376407 - Flags: review+
The patch is bug 492037 has a success test for this. I'll add a fail case.
Blocks: 492037
Keywords: checkin-needed
Attachment #376407 - Flags: approval1.9.1+
Status: ASSIGNED → RESOLVED
Closed: 16 years ago
Keywords: checkin-needed
Resolution: --- → FIXED
Could this have caused crashtest 441785-1.xul to have started to fail?
Flags: in-testsuite?
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Creator:
Created:
Updated:
Size: