DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG 
RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT
<http://nagoya.apache.org/bugzilla/show_bug.cgi?id=12127>.
ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND 
INSERTED IN THE BUG DATABASE.

http://nagoya.apache.org/bugzilla/show_bug.cgi?id=12127

Null Pointer Exception for included stylesheet that has unbounded extension prefix

           Summary: Null Pointer Exception for included stylesheet that has
                    unbounded extension prefix
           Product: XalanJ2
           Version: 2.4Dx
          Platform: PC
        OS/Version: Other
            Status: NEW
          Severity: Normal
          Priority: Other
         Component: org.apache.xalan.transformer
        AssignedTo: [EMAIL PROTECTED]
        ReportedBy: [EMAIL PROTECTED]


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

Reply via email to