You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@cocoon.apache.org by bu...@apache.org on 2002/06/25 08:39:21 UTC

DO NOT REPLY [Bug 10203] New: - NPE when using document() in XSLT

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=10203>.
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=10203

NPE when using document() in XSLT

           Summary: NPE when using document() in XSLT
           Product: Cocoon 2
           Version: 2.0.3
          Platform: Other
        OS/Version: Other
            Status: NEW
          Severity: Normal
          Priority: Other
         Component: sitemap components
        AssignedTo: cocoon-dev@xml.apache.org
        ReportedBy: j3322ptm@yahoo.de


There is a NPE thrown from the 1.18.2.1 revision of
o.a.c.components.xslt.XSLTProcessorImpl.java because resolve() is called to
resolve the URI passed to document(), and the "includes" field is null in
this line
 includes.add(new Object[]{xslSource.getSystemId(),
    new Long(xslSource.getLastModified())});
The "includes" is only set during style sheet compilation.
The comment at the beginning exhibit a wrong assumtion conneted to the fault:
   /** Resolver used to resolve XSL includes */
    protected SourceResolver resolver;
A simple pipeline with an XSL transformation involving an arbitrary call to
document() should reproduce the problem.

The information of URIs referenced during the pipeline run gathered by
resolve() should be used for cache control for the pipeline result the same
way it is now used for validating the compiled style sheet.

---------------------------------------------------------------------
To unsubscribe, e-mail: cocoon-dev-unsubscribe@xml.apache.org
For additional commands, email: cocoon-dev-help@xml.apache.org