Closed
Bug 318563
Opened 20 years ago
Closed 20 years ago
Firefox crashes when xslt processor uses document() function to access itself.
Categories
(Core :: XSLT, defect)
Tracking
()
RESOLVED
DUPLICATE
of bug 205778
People
(Reporter: ibjoel, Assigned: peterv)
Details
(Keywords: crash, stackwanted)
User-Agent: Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.8) Gecko/20051111 Firefox/1.5
Build Identifier: Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.8) Gecko/20051111 Firefox/1.5
if an xpath expression is given which uses the document function to reference the current xslt file in a transformation eg.
select="document('')/sometag"
or
select="document('this file')/sometag"
firefox crashes.
Reproducible: Always
Steps to Reproduce:
1.create an xslt document which accesses a value within itself with 'document()'
eg.
<?xml version="1.0"?>
<xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform">
<xsl:variable name="x">
<h1>Some Value</h1>
</xsl:variable>
<xsl:template match="/">
<html>
<body>
<xsl:copy-of select="document('')/xsl:stylesheet/xsl:variable/h1"/>
</body>
</html>
</xsl:template>
</xsl:stylesheet>
2. Link the stylesheet to any xml document.
3. open the xml document in firefox
Actual Results:
firefox crashes trying to apply the stylesheet.
Expected Results:
Normal output (as in msie 6 and php default xslt processor) or at least an error
I have only tried having firefox open the xml document and applying the xsl document automatically - have not attempted the transformat vie javascript.
This is an easy work around to the lack of a node-set() function
Comment 1•20 years ago
|
||
Do you think you could attach a testcase showing the problem? You can attach the XML stylesheet as an attachment and then use that attachment's URL in the XML file.
Severity: normal → critical
Assignee: nobody → peterv
Component: General → XSLT
Keywords: crash,
stackwanted
Product: Firefox → Core
QA Contact: general → keith
Version: unspecified → 1.8 Branch
| Assignee | ||
Comment 2•20 years ago
|
||
*** This bug has been marked as a duplicate of 205778 ***
Status: UNCONFIRMED → RESOLVED
Closed: 20 years ago
Resolution: --- → DUPLICATE
You need to log in
before you can comment on or make changes to this bug.
Description
•