Hi,

I'm currently facing exactly the same problem. This somehow seems to be
related to log4j beeing included in the classpath of the java call and using
percent values to specify the column width in a table.

The attached fo-file can be transformed to PDF without log4j beeing in the
classpath like a charm, but with log4j in the classpath it produces a
StackOverflowError:

C:\home\dahepe>fop-0.95\fop.bat -fo log4j.fo -pdf log4j.pdf
log4j:WARN No appenders could be found for logger
(org.apache.fop.util.ContentHandlerFactoryRegistry).
log4j:WARN Please initialize the log4j system properly.
Exception in thread "main" java.lang.StackOverflowError
...
at java.lang.String.valueOf(String.java:2615)
at java.lang.StringBuffer.append(StringBuffer.java:220)
at org.apache.fop.datatypes.LengthBase.toString(LengthBase.java:135)
at java.lang.String.valueOf(String.java:2615)
at java.lang.StringBuffer.append(StringBuffer.java:220)
at
org.apache.fop.fo.properties.PercentLength.toString(PercentLength.java:121)
at java.lang.String.valueOf(String.java:2615)
at java.lang.StringBuffer.append(StringBuffer.java:220)
at org.apache.fop.fo.flow.table.TableColumn.toString(TableColumn.java:233)
at java.lang.String.valueOf(String.java:2615)
at java.lang.StringBuffer.append(StringBuffer.java:220)
at org.apache.fop.datatypes.LengthBase.toString(LengthBase.java:135)
at java.lang.String.valueOf(String.java:2615)
at java.lang.StringBuffer.append(StringBuffer.java:220)
at
org.apache.fop.fo.properties.PercentLength.toString(PercentLength.java:121)
at java.lang.String.valueOf(String.java:2615)

As mentioned the only difference between a working and non working call is
log4j in the classpath. Thus to get the error the classpath declaration in
my fop.bat changed a little:
...
set LOCALCLASSPATH=%LOCALCLASSPATH%;%LIBDIR%\fop-hyph.jar
set LOCALCLASSPATH=%LOCALCLASSPATH%;%LIBDIR%\log4j-1.2.15.jar
set LOCALCLASSPATH=%LOCALCLASSPATH%;%FOP_HYPHENATION_PATH%
...

I stumbled across this bug while trying to use fop embedded in an other
application. Thus removing log4j from the classpath is not an option. As a
workaround I replaced the percent column width entries with
proportional-column-width(XX), which produces the same results in the
output.

>I'm not entirely certain, but it seems like the fix never made it  
>into 0.95. IIC, this issue should not exist in FOP Trunk anymore.

>Can you verify this, or send us the related FO, so we can verify  
>ourselves?

Is there a release schedule for fop0.96 and will this bug be fixed in the
next stable version??

Best regards,
Daniel

http://www.nabble.com/file/p20832245/log4j.fo log4j.fo 
-- 
View this message in context: 
http://www.nabble.com/FOP-0.93-vs-0.94-vs-0.95-tp19141580p20832245.html
Sent from the FOP - Users mailing list archive at Nabble.com.


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

Reply via email to