Closed
Bug 132238
Opened 22 years ago
Closed 22 years ago
Mozilla doesn't show page content; support <!> and <!foo> comments
Categories
(Core :: DOM: HTML Parser, defect, P2)
Core
DOM: HTML Parser
Tracking
()
VERIFIED
FIXED
mozilla1.0
People
(Reporter: relf, Assigned: hjtoi-bugzilla)
References
()
Details
(Keywords: regression, Whiteboard: [fixinhand])
Attachments
(2 files, 1 obsolete file)
147 bytes,
text/html
|
Details | |
1.20 KB,
patch
|
harishd
:
review+
jst
:
superreview+
asa
:
approval+
|
Details | Diff | Splinter Review |
From Bugzilla Helper: User-Agent: Mozilla/5.0 (OS/2; U; Warp 4.5; en-US; rv:0.9.9+) Gecko/20020319 BuildID: 2002031916 Latest Mozilla shows empty page instead of actual content. Release 0.9.9 version worked fine on this page but in the latest night builds something was broken. ;-( Reproducible: Always Steps to Reproduce: 1. Go to given URL 2. 3.
Comment 1•22 years ago
|
||
To parser (there are no nodes, so nothing to lay out). The page has: <!doctype html public "HTML 4.0"> <!ThIs PaGe Is ToTaLly HaNd MaDe By DaNiEl CaEtAnO uSiNg Os/2 sYsTeM eDiToR> Removing either line makes things work. ccing heikki because this is likely related to the recent comment-parsing changes.... Seeing this on Linux as well.
Assignee: attinasi → harishd
Status: UNCONFIRMED → NEW
Component: Layout → Parser
Ever confirmed: true
OS: OS/2 → All
QA Contact: petersen → moied
Hardware: PC → All
Assignee | ||
Comment 2•22 years ago
|
||
Assignee | ||
Comment 3•22 years ago
|
||
Assignee | ||
Comment 4•22 years ago
|
||
The doctype line kicks us into strict mode, and it could be argued that perhaps in this case it shouldn't. Our strict comment parsing follows exactly what HTML 4.01 specifies is a comment: http://www.w3.org/TR/html4/intro/sgmltut.html#h-3.2.4 This is an argument that we should NOT fix the strict comment parsing code (but maybe we should fix "strict detection"). However, one can also argue that because SGML itself allows (although HTML 4.01 prohibits this) a short comment of the form: <!> and because our old code supported that as well as the completely bogus form: <!This is foobar> we should be backwards compatible and/or follow SGML in this matter. Comments?
Status: NEW → ASSIGNED
Keywords: regression
Comment 5•22 years ago
|
||
Hi ho. The relevant SGML production is: [91] comment declaration = mdo ( comment, ( s | comment )* )?, mdc where mdo is "<!", mdc is ">", and a comment is two comment delimiters (--) and the data between them. The "?" indicates that the preceding expression is repeatable zero or one times. So <!-- comment -->, <!-- comment -- --comment -->, and <!> are all legitimate in SGML. (It does seem odd that the expression isn't marked as repeatable one or more times, but go figure.) My inclination would be to fix the strict comment parsing to handle "<!>" (I regard the attempt of the HTML spec to disallow legitimate SGML constructs as so much nonsense) and punt this particular case to evangelism.
Assignee | ||
Comment 6•22 years ago
|
||
There is also the forwards compatibility argument: in XML <!> is a fatal well-formedness error. This is an argument that we should NOT fix this.
Assignee: harishd → heikki
Status: ASSIGNED → NEW
Assignee | ||
Updated•22 years ago
|
Status: NEW → ASSIGNED
Priority: -- → P2
Target Milestone: --- → mozilla1.0
Assignee | ||
Comment 7•22 years ago
|
||
Attachment #75280 -
Attachment is obsolete: true
Assignee | ||
Updated•22 years ago
|
Summary: Mozilla doesn't show page content → Mozilla doesn't show page content; support <!> and <!foo> comments
Whiteboard: [fixinhand]
Assignee | ||
Comment 8•22 years ago
|
||
Bug 110544 was the one that caused this.
Comment on attachment 75675 [details] [diff] [review] better fix, the outer if condition was always true r=harishd
Attachment #75675 -
Flags: review+
Comment 10•22 years ago
|
||
Comment on attachment 75675 [details] [diff] [review] better fix, the outer if condition was always true sr=jst
Attachment #75675 -
Flags: superreview+
Comment 11•22 years ago
|
||
Comment on attachment 75675 [details] [diff] [review] better fix, the outer if condition was always true a=asa (on behalf of drivers) for checkin to the 1.0 trunk
Attachment #75675 -
Flags: approval+
Assignee | ||
Comment 12•22 years ago
|
||
Checked in.
Status: ASSIGNED → RESOLVED
Closed: 22 years ago
Resolution: --- → FIXED
You need to log in
before you can comment on or make changes to this bug.
Description
•