Details
-
Bug
-
Status: Resolved
-
Resolution: Fixed
-
2.4Dx
-
None
-
None
-
Operating System: Other
Platform: PC
-
12127
Description
In a specific configuration of stylesheets (which I can only describe by
including below), a NullPointerException is thrown.
Particularly, I have an included stylesheet called subpage.xsl whose stylesheet
tag has the attribute extension-element-prefixes="someprefix". someprefix is
not already declared as a namespace.
When I remove the xmlns:html attribute from the subpage.xsl stylesheet tag, the
null pointer exception goes away.
I do not understand the following bugs, so I cannot tell if they are duplicates.
But these bugs sound like they are similar:
Bug 11792
Bug 9683
I am using JDK1.3.0_02 on WindowsMe, using Xalan 2.4D1
The command was:
"%JAVAHOME%\bin\java.exe" -classpath "%XALANCLASSPATH%"
org.apache.xalan.xslt.Process -IN file.xml -XSL toppage.xsl -out result.xml
+++++++++++++++++
toppage.xsl:
<?xml version="1.0"?>
<xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
version="1.0"
>
<xsl:include href="subpage.xsl"/>
</xsl:stylesheet>
+++++++++++++++++
subpage.xsl
<?xml version="1.0"?>
<xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
xmlns:html="http://www.w3.org/TR/REC-html40"
version="1.0"
extension-element-prefixes="someprefix">
</xsl:stylesheet>
+++++++++++
file.xml
<?xml version="1.0" encoding="UTF-8"?>
<thetag/>
+++++++++++
Exception message:
(Location of error unknown)XSLT Error (javax.xml.transform.TransformerConfigurat
ionException): javax.xml.transform.TransformerException: java.lang.NullPointerEx
ception