--- /cygdrive/c/fopdiff/fop-0.20.4/src/org/apache/fop/fo/flow/Block.java 2002-07-05 15:06:18.000000000 -0400 +++ ./Block.java 2002-11-27 15:49:23.000000000 -0500 @@ -58,12 +58,15 @@ int areaHeight = 0; int contentWidth = 0; + int infLoopThreshhold = 50; String id; int span; // this may be helpful on other FOs too boolean anythingLaidOut = false; + //Added to see how long it's been since nothing was laid out. + int noLayoutCount = 0; public Block(FObj parent, PropertyList propertyList) throws FOPException { @@ -77,6 +80,14 @@ public Status layout(Area area) throws FOPException { BlockArea blockArea; + if (!anythingLaidOut) { + noLayoutCount++; + } + if (noLayoutCount > infLoopThreshhold) { + throw new FOPException( + "No meaningful layout in block after many attempts. "+ + "Infinite loop is assumed. Processing halted."); + } // log.error(" b:LAY[" + marker + "] ");