Closed
Bug 5682
Opened 26 years ago
Closed 26 years ago
Error in Expat Tokenizer does not stop parsing process
Categories
(Core :: XML, defect, P1)
Tracking
()
VERIFIED
FIXED
M7
People
(Reporter: sdm, Assigned: harishd)
Details
(Whiteboard: 7/9 I need to develop a testcase for this. Will do monday.)
If I change the header of http://pimpmaster.org/simeon/xultool to:
<window xmlns:html="http://www.w3.org/TR/REC-html40"
xmlns="http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul"
style="margin: 0px;/*overflow: scroll*/"
<!-- onload="Startup();"-->
>
I get this in the terminal window:
Using Expat for parsing XML...
XML Error in file
'file:////usr/local/mozilla/dist/bin/res/samples/xultool-create.xul', Line
Number: 17, Col Number: 0, Description: not well-formed
Source Line: <!-- onload="Startup();"-->
Segmentation fault (core dumped)
Updated•26 years ago
|
Status: NEW → ASSIGNED
Target Milestone: M6
Comment 1•26 years ago
|
||
Setting TFV to M6 and accepting bug...
Updated•26 years ago
|
Assignee: nisheeth → harishd
Status: ASSIGNED → NEW
Summary: <!-- comments within a XUL tag cause crash. → Error in Expat Tokenizer does not stop parsing process
Target Milestone: M6 → M7
Comment 2•26 years ago
|
||
The XML spec says that comments within a tag are not allowed (see
http://www.w3.org/TR/1998/REC-xml-19980210#sec-comments). So, the error
reported by expat is not a bug.
The real problem is that we crash in some cases when expat reports an error.
The reason for that behavior is that the expat tokenizer has no way to tell the
parser (nsParser) to stop processing buffers after an error is reported by the
expat parser. So, right now, there is a hack in the expat tokenizer which
ignores all buffers passed in after an error is seen by the tokenizer. We
need to remove the hack and do the right thing: stop the parse process when an
error occurs. Harish has this task on his plate. Re-assigning the bug to him.
This is probably not going to make the M6 milestone, so setting the milestone to
M7.
Updated•26 years ago
|
QA Contact: 4110 → 3847
Status: ASSIGNED → RESOLVED
Closed: 26 years ago
Resolution: --- → FIXED
Checked in code, yesterday, that would allow parser to respond to errors from
XML,PICS, etc.. and "stop parsing" if necessary.
Marking the bug fixed.
Updated•26 years ago
|
Whiteboard: 6/18 awaiting developer response
Comment 4•26 years ago
|
||
Harish, when I try to go to the listed URL in the example
http://pimpmaster.org/simeon/xultool
I get bumped over to mozillazine. Is there a local test I can look at and run
to verify this bug? Thanks!
Comment 6•26 years ago
|
||
Jan, this bug can be verified by modifying any of our XUL files such that there
is a comment *within* a tag. The XML parser should emit an error to the console
but the app should not crash. Without Harish's fix, the app was crashing.
Updated•26 years ago
|
Whiteboard: 6/18 awaiting developer response → 7/9 I need to develop a testcase for this. Will do monday.
Updated•26 years ago
|
Status: RESOLVED → VERIFIED
Comment 7•26 years ago
|
||
Verified fixt on Linux
Build ID: 1999071308
(Also checked and verified on NT)
You need to log in
before you can comment on or make changes to this bug.
Description
•