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

http://issues.apache.org/bugzilla/show_bug.cgi?id=29053

StackOverflowError occurs when recursive call of template is performed many times.

           Summary: StackOverflowError occurs when recursive call of
                    template is performed many times.
           Product: XalanJ2
           Version: 2.5
          Platform: PC
        OS/Version: Windows XP
            Status: NEW
          Severity: Critical
          Priority: Other
         Component: org.apache.xalan.transformer
        AssignedTo: [EMAIL PROTECTED]
        ReportedBy: [EMAIL PROTECTED]


[Summary]
StackOverflowError occurs when recursive call of template is performed many 
times.

[Version]
I tested this bug using the following versions.

Xalan
- XalanJ2 2.5.1
- XalanJ2 2.6.0
- Xalan included in JRE 1.4.1_03

OS/JVM
- Windows XP Professional Version 2002 Service Pack1
- Java(TM) 2 Runtime Environment, Standard Edition (build 1.4.1_03-b02)

[How to reproduce this bug]
(1) Please download the following attached files into same folder.
a. StackOverflowErrorTest.java
b. stackoverflow.xsl
  (This xslt is from "XSLT Bible" written by Michael Kay)

(2) Please compile StackOverflowErrorTest.java and execute 
StackOverflowErrorTest.StackOverflowError occurs.

[Memo]
(1) This bug doesn't occur when "bookCount" is small.
example:

line12:  int bookCount = 10; // -> Succeed
line12:  int bookCount = 100; // -> Succeed
line12:  int bookCount = 1000; // -> StackOverflowError

(2) I tried to set recursion limit using
org.apache.xalan.transformer.TransformerImpl#setRecursionLimit(int).
The result was:

transformerImpl.setRecursionLimit(-1); // -> StackOverflowError
transformerImpl.setRecursionLimit(100000); // -> StackOverflowError
transformerImpl.setRecursionLimit(1000000); // -> StackOverflowError

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to