[
https://issues.apache.org/jira/browse/COMPRESS-127?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13010060#comment-13010060
]
Doron Cohen commented on COMPRESS-127:
--------------------------------------
hi Sebb, thanks for looking into this!
bq. because the BZip2 version closes the wrapped stream,
I verified this in LUCENE-2980 where I put a workaround for this - indeed, it
is not needed for BZip2, only for GZIP.
> Calling close() on inputStream returned by
> CompressorStreamFactory.createCompressorInputStream() does not close the
> underlying input stream
> -------------------------------------------------------------------------------------------------------------------------------------------
>
> Key: COMPRESS-127
> URL: https://issues.apache.org/jira/browse/COMPRESS-127
> Project: Commons Compress
> Issue Type: Bug
> Components: Compressors
> Reporter: Doron Cohen
> Attachments: CreateCompressorInputStreamTest.java
>
>
> When creating and closing a stream like this:
> {code}
> InputStream is =
> csFactory.createCompressorInputStream(CompressorStreamFactory.GZIP, in);
> is.close();
> {code}
> The underlying stream *in* is not closed.
> It seems like a bug - for instance it prevents from deleting the file on
> which that stream was opened.
--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira