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=6022>. 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=6022 NPE and other exceptions re-using simple transformer.transform() Summary: NPE and other exceptions re-using simple transformer.transform() Product: XalanJ2 Version: CurrentCVS Platform: All OS/Version: All Status: NEW Severity: Critical Priority: Other Component: org.apache.xalan.transformer AssignedTo: [EMAIL PROTECTED] ReportedBy: [EMAIL PROTECTED] A number of stylesheets throw NPE's or other exceptions when simply re-using the same transformer object to call transform() several times in a row in the same thread. I'll list each of the simple ways to reproduce: TestID: TransformerAPITest.java testCase5 r1.16 xml-xalan-CVS 24-Jan-02 4PM (eastern) This test uses an identity transformer multiple times which works fine. It then uses a stylesheet with a global variable, and throws NPE the second time that transform() is called: ... java.lang.NullPointerException at org.apache.xpath.objects.XNodeSet.dispatchCharactersEvents (XNodeSet.java:262) at org.apache.xpath.Expression.executeCharsToContentHandler (Expression.java:303) at org.apache.xalan.templates.ElemValueOf.execute(ElemValueOf.java:319) ... Running 'build conf -Dconf.flavor=trax.systemId3' will throw exceptions in a number of conformance tests. trax.systemId3 is TraxSystemId3Wrapper.java, which simply uses StreamSources from systemId's, and then calls .transform() three times in a row for each conformance test. There are several different common stack traces, but they all involve an NPE on the second time that transform() is called. See attached file for log.
