pdfbox-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Tilman Hausherr <THaush...@t-online.de>
Subject Re: PDFBox*.tmp files not deleted by PDFParser
Date Tue, 24 May 2016 18:10:27 GMT
did you close the options object?

Tilman

Am 24.05.2016 um 15:51 schrieb Damien Butaye:
> Dear all,
>
>    I'm trying to add a signature to a PDF using PDFBOX 2.0.1. During the
> process, a tmp file (e.g: tmpPDFBoxXXX.pdf) is stored inside the /tmp
> directory (RehHat server). This file is not deleted after completion.
> After some checks, it seems that the object responsible of the file
> creation is  "RandomAccessBufferedFileInputStream(InputStream is)". This
> object is used by the PDFParser object which doesn't close the stream after
> completion.
>
> The release note 2.0.0 [PDFBOX-2723] seems to handle this bug by adding the
> following line (see https://issues.apache.org/jira/browse/PDFBOX-2723) in
> the COSParser :
>
> xrefStream.close(); // <--- *** NEW LINE ***
>
> But, in debug mode, I saw this line is never reached so the stream is not
> closed and the tmp file is not deleted. Has anybody a workaround to handle
> this ?
> Thanks for your help!
>


---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@pdfbox.apache.org
For additional commands, e-mail: users-help@pdfbox.apache.org


Mime
View raw message