Closed
Bug 418391
Opened 17 years ago
Closed 17 years ago
Local XHTML does not load (considered invalid) if a non-existent CSS file is specified.
Categories
(Core :: XML, defect)
Tracking
()
VERIFIED
FIXED
mozilla1.9
People
(Reporter: Aleksej, Assigned: MatsPalmgren_bugz)
References
(Depends on 1 open bug)
Details
(Keywords: regression, testcase)
Attachments
(4 files, 2 obsolete files)
381 bytes,
application/xhtml+xml
|
Details | |
16.95 KB,
image/png
|
Details | |
1.08 KB,
patch
|
bzbarsky
:
review+
bzbarsky
:
superreview+
mtschrep
:
approval1.9+
|
Details | Diff | Splinter Review |
3.11 KB,
patch
|
Details | Diff | Splinter Review |
Mozilla/5.0 (X11; U; Linux i686 (x86_64); eo; rv:1.9b4pre) Gecko/2008021804 Minefield/3.0b4pre
Mozilla/5.0 (X11; U; Linux i686 (x86_64); en-US; rv:1.9b4pre) Gecko/2008021902 SeaMonkey/2.0a1pre
Steps to reproduce:
1. Have a valid XHTML document with a CSS file specified using the <link> attribute (see the attachment).
2. Try loading it from disk (the bug does not show up through HTTP):
a) When the CSS file does exist.
b) When the CSS file does not exist.
Actual results:
2a: WFM
2b:
XML Parsing Error:
Location: file:///dev/shm/02/test.xhtml
Line Number 6, Column 71: <link href="style.css" rel="stylesheet" type="text/css" media="all"/>
-----------------------------------------------------------------------------^
Regression range:
Fx 2007111804…2007111904
SM 2007111902…2007112002
→ bug 401613
See also: bug 404419.
Flags: blocking1.9?
Assignee | ||
Comment 1•17 years ago
|
||
Attachment #304296 -
Flags: superreview?(bzbarsky)
Attachment #304296 -
Flags: review?(bzbarsky)
Assignee | ||
Comment 2•17 years ago
|
||
Comment 3•17 years ago
|
||
Comment on attachment 304296 [details] [diff] [review]
Like so?
I don't think the CSSLoader is the right place to be doing this. We should either do it like bug 404419 (CSS loading errors really should not be fatal to XML parsing) or finally fix that file channel bug so they won't throw from AsyncOpen. Or both!
Attachment #304296 -
Flags: superreview?(bzbarsky)
Attachment #304296 -
Flags: superreview-
Attachment #304296 -
Flags: review?(bzbarsky)
Attachment #304296 -
Flags: review-
Updated•17 years ago
|
Flags: tracking1.9? → blocking1.9?
Would it make sense to land the current patch for now and do the AsyncOpen thing after we've branched for FF3. It seems scary to fix that this close to release.
Or ideal would be to do what Boris says in comment 3. Mats would you be able to write up such a patch?
Assignee: nobody → mats.palmgren
Flags: wanted1.9.0.x+
Flags: wanted1.9+
Flags: blocking1.9?
Flags: blocking1.9-
Forgot to say:
Don't think this is a blocker given that local files are rare, XHTML is rare, and failed CSS is rare, and having all three happen at the same time seems very very rare.
Comment 7•17 years ago
|
||
I'm the original reporter of bug #422735 that has just been marked as a duplicate of this one.
It seems that this bug does not impact local files only, but also XHTML documents stored in strings, and then parsed with DOMParser::parseFromString().
Therefore it will probably break some online apps, such as the LiveRC tool on Wikipedia <http://fr.wikipedia.org/wiki/Utilisateur:EDUCA33E/LiveRC/Documentation>. Indeed, LiveRC tries to parse an XHTML document contained in a string. This works fine in Firefox 2, but fails in Firefox 3b4. I think that this issue should be fixed in Firefox 3.
Reporter | ||
Updated•17 years ago
|
OS: Linux → All
Assignee | ||
Comment 8•17 years ago
|
||
(In reply to comment #3)
> I don't think the CSSLoader is the right place to be doing this.
The CSSLoader part just adds a warning to the Error Console.
The fix is in nsStyleLinkElement.
(In reply to comment #4)
> Mats would you be able to write up such a patch?
Probably not, since I think my patch does it "like bug 404419" so I don't
understand what Boris is asking for...
Comment 9•17 years ago
|
||
> The fix is in nsStyleLinkElement.
Ah, indeed. I'm OK with that. I don't think we want the CSSLoader change.
Assignee | ||
Comment 10•17 years ago
|
||
Ok, without the warning message then...
Attachment #304296 -
Attachment is obsolete: true
Attachment #311454 -
Flags: superreview?(bzbarsky)
Attachment #311454 -
Flags: review?(bzbarsky)
Assignee | ||
Comment 11•17 years ago
|
||
Comment 12•17 years ago
|
||
Comment on attachment 311454 [details] [diff] [review]
Patch rev. 2
Please make sure to file a followup bug (dependent on the file:// protocol thing) to remove this once we fix the protocol handler.
Attachment #311454 -
Flags: superreview?(bzbarsky)
Attachment #311454 -
Flags: superreview+
Attachment #311454 -
Flags: review?(bzbarsky)
Attachment #311454 -
Flags: review+
Assignee | ||
Comment 13•17 years ago
|
||
Attachment #311456 -
Attachment is obsolete: true
Assignee | ||
Updated•17 years ago
|
Attachment #311454 -
Flags: approval1.9?
Assignee | ||
Comment 14•17 years ago
|
||
(In reply to comment #12)
Filed bug 424880
Updated•17 years ago
|
Attachment #311454 -
Flags: approval1.9? → approval1.9+
Assignee | ||
Comment 15•17 years ago
|
||
mozilla/content/base/src/nsStyleLinkElement.cpp 1.48
-> FIXED
Status: NEW → RESOLVED
Closed: 17 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla1.9
Reporter | ||
Comment 17•17 years ago
|
||
Verified fixed with Mozilla/5.0 (X11; U; Linux i686; eo; rv:1.9pre) Gecko/2008042304 Minefield/3.0pre.
Status: RESOLVED → VERIFIED
Updated•16 years ago
|
Flags: wanted1.9.0.x+
You need to log in
before you can comment on or make changes to this bug.
Description
•