pdfbox-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Maruan Sahyoun <sahy...@fileaffairs.de>
Subject Re: IndexOutOfBoundsException when saving
Date Fri, 26 Apr 2013 16:57:41 GMT
there was an issue with RandomAccessBuffer which is fixed in 1.8.1 - give it a try.

BR

Maruan Sahyoun

Am 26.04.2013 um 18:45 schrieb James Green <james.mk.green@gmail.com>:

> Is this something fixed in a recent release? We're using 1.7.1:
> 
> org.apache.pdfbox.exceptions.COSVisitorException:
> java.lang.IndexOutOfBoundsException:
> Index: 28, Size: 0
>    at org.apache.pdfbox.pdfwriter.COSWriter.visitFromStream(
> COSWriter.java:1245)
>    at org.apache.pdfbox.cos.COSStream.accept(COSStream.java:201)
>    at org.apache.pdfbox.cos.COSObject.accept(COSObject.java:206)
>    at org.apache.pdfbox.pdfwriter.COSWriter.doWriteObject(
> COSWriter.java:524)
>    at org.apache.pdfbox.pdfwriter.COSWriter.doWriteBody(COSWriter.java:434)
>    at org.apache.pdfbox.pdfwriter.COSWriter.visitFromDocument(
> COSWriter.java:1056)
>    at org.apache.pdfbox.cos.COSDocument.accept(COSDocument.java:496)
>    at org.apache.pdfbox.pdfwriter.COSWriter.write(COSWriter.java:1392)
>    at org.apache.pdfbox.pdmodel.PDDocument.save(PDDocument.java:1157)
>    at org.apache.pdfbox.pdmodel.PDDocument.save(PDDocument.java:1138)
> ...
> Caused by: java.lang.IndexOutOfBoundsException: Index: 28, Size: 0
>    at java.util.ArrayList.rangeCheck(ArrayList.java:604)
>    at java.util.ArrayList.get(ArrayList.java:382)
>    at org.apache.pdfbox.io.RandomAccessBuffer.seek(
> RandomAccessBuffer.java:84)
>    at org.apache.pdfbox.io.RandomAccessFileInputStream.read(
> RandomAccessFileInputStream.java:96)
>    at java.io.BufferedInputStream.fill(BufferedInputStream.java:235)
>    at java.io.BufferedInputStream.read1(BufferedInputStream.java:275)
>    at java.io.BufferedInputStream.read(BufferedInputStream.java:334)
>    at org.apache.pdfbox.pdfwriter.COSWriter.visitFromStream(
> COSWriter.java:1232)


Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message