From 80b40cf372060cf16008325cb0d86bd7e2a03a9c Mon Sep 17 00:00:00 2001 From: Jeremias Maerki Date: Wed, 18 Aug 2010 12:56:51 +0000 Subject: [PATCH] Bugfix for potential java.lang.IndexOutOfBoundsException in PDFDocument.outputTrailer(). git-svn-id: https://svn.apache.org/repos/asf/xmlgraphics/fop/trunk@986650 13f79535-47bb-0310-9956-ffa450edef68 --- src/java/org/apache/fop/pdf/PDFDocument.java | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/src/java/org/apache/fop/pdf/PDFDocument.java b/src/java/org/apache/fop/pdf/PDFDocument.java index ae160ef78..a17c8c4df 100644 --- a/src/java/org/apache/fop/pdf/PDFDocument.java +++ b/src/java/org/apache/fop/pdf/PDFDocument.java @@ -1017,9 +1017,7 @@ public class PDFDocument { output(stream); for (int count = 0; count < this.trailerObjects.size(); count++) { PDFObject o = (PDFObject)this.trailerObjects.get(count); - this.location.set( - o.getObjectNumber() - 1, - new Integer(this.position)); + setLocation(o.getObjectNumber() - 1, this.position); this.position += o.output(stream); } /* output the xref table and increment the character position -- 2.39.5