Where? Here's the code that causes that:

PDFMergeUtility util = new PDFMergeUtility();

for (File file : set) {
try{
if( file.exists() ){
        util.addSource(file);
}
    } catch ( Exception e ){
       //log e
    }
 }
util.setDestinationFileName(...);

util.mergeDocuments();


On Thu, Mar 13, 2014 at 11:27 AM, Maruan Sahyoun <sahy...@fileaffairs.de>wrote:

> Hi,
>
> not a direct answer to your question but could you try
> PDDocument.loadNonSeq instead?
>
> BR
> Maruan Sahyoun
>
> > Am 13.03.2014 um 16:16 schrieb Alin Mazilu <impet...@gmail.com>:
> >
> > Hello guys,
> >
> >
> > Has anyone had any problem with this? Any idea why it happens? What would
> > be a good value for pushBackSize so this does not happen? Thanks!
> >
> >
> > Partial stack trace:
> >
> >
> > org.apache.pdfbox.exceptions.WrappedIOException: Could not push back
> 72940
> > bytes in order to reparse stream. Try increasing push back buffer using
> > system property org.apache.pdfbox.baseParser.pushBackSize
> >
> >
> >
> >                at
> >
> org.apache.pdfbox.pdfparser.BaseParser.parseCOSStream(BaseParser.java:546)
> >
> >
> >
> >                at
> > org.apache.pdfbox.pdfparser.PDFParser.parseObject(PDFParser.java:566)
> >
> >
> >
> >                at
> > org.apache.pdfbox.pdfparser.PDFParser.parse(PDFParser.java:187)
> >
> >
> >
> >                at
> > org.apache.pdfbox.pdmodel.PDDocument.load(PDDocument.java:1071)
> >
> >
> >
> >                at
> > org.apache.pdfbox.pdmodel.PDDocument.load(PDDocument.java:1038)
> >
> >
> >
> >                at
> >
> org.apache.pdfbox.util.PDFMergerUtility.mergeDocuments(PDFMergerUtility.java:186)
>

Reply via email to