Closed
Bug 513923
Opened 15 years ago
Closed 15 years ago
[HTML5] HTML5 parser fails layout/reftests/bugs/495385-1c.html
Categories
(Core :: DOM: HTML Parser, defect)
Tracking
()
RESOLVED
FIXED
People
(Reporter: bzbarsky, Assigned: Ms2ger)
References
Details
Attachments
(1 file)
(deleted),
patch
|
bzbarsky
:
review+
|
Details | Diff | Splinter Review |
And also fails tests d,e,f for the same bug. The failure mode is an extra blank line at the end of the <body>. I looked at the DOM produced, and the last textnode in the <body> has two trailing \n for some reason. I can't see a reason why they'd be there from the source.
Assignee | ||
Comment 1•15 years ago
|
||
It is the newline between </body> and </html>. I believe this is intentional.
![]() |
Reporter | |
Comment 2•15 years ago
|
||
Ah, seems like that's the case yes (as far as which newline it is). If that's intentional, the reftests need to be updated.
Assignee | ||
Comment 3•15 years ago
|
||
This is indeed intentional. This patch just removes the newlines. Going through the algorithm, starting right before "</body>": 1. We're in "in body", with the body as the current node. 2. We see an end tag whose tag name is "body" and move into "after body", without changing the current node. [1] 3. We see a LF, which is to be processed using the rules of "in body". [2] 4. We then insert the character into the current node. [1] [1] http://www.whatwg.org/specs/web-apps/current-work/multipage/syntax.html#parsing-main-inbody [2] http://www.whatwg.org/specs/web-apps/current-work/multipage/syntax.html#parsing-main-afterbody
Attachment #397893 -
Flags: review?(bzbarsky)
![]() |
Reporter | |
Updated•15 years ago
|
Attachment #397893 -
Flags: review?(bzbarsky) → review+
![]() |
Reporter | |
Comment 4•15 years ago
|
||
Pushed http://hg.mozilla.org/mozilla-central/rev/d03e60fb8f80 Thanks for the fix!
Assignee: nobody → Ms2ger
Status: NEW → RESOLVED
Closed: 15 years ago
Flags: in-testsuite+
Resolution: --- → FIXED
You need to log in
before you can comment on or make changes to this bug.
Description
•