[
https://issues.apache.org/jira/browse/PDFBOX-1888?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13892537#comment-13892537
]
Tilman Hausherr commented on PDFBOX-1888:
-----------------------------------------
2.0.0 is also affected.
> JBIG2Filter is creating an ImageInputStream (with temp file) and not closing
> it
> -------------------------------------------------------------------------------
>
> Key: PDFBOX-1888
> URL: https://issues.apache.org/jira/browse/PDFBOX-1888
> Project: PDFBox
> Issue Type: Bug
> Affects Versions: 1.8.4
> Environment: Java 1.6.0.
> levigo-jbig2-imageio-1.6.1.jar
> Reporter: Tim Cameron
> Attachments: JBIG2Filter.patch
>
>
> Our application is processing JBIG2 encoded PDFs and is not restarted on a
> regular basis. When calling pdPage.convertToImage() a temporary file is
> created and never closed. After some time, the limit (1024 in our case) for
> open file handles is being hit and we cannot process any more documents. I
> debugged the code and found the culprit to be pdfbox/filter/JBIG2Filter.java.
> It is calling ImageIO.createImageInputStream() to create a new
> ImageInputStream for the ImageReader, but this stream is never being closed.
> A temporary file is being created (/tmp/imageio<randomNumber>.tmp) as part of
> this call and remains open if the stream isn't closed.
--
This message was sent by Atlassian JIRA
(v6.1.5#6160)