Kevin Dauch created COMPRESS-255:
------------------------------------

             Summary: BZip2CompressorInputStream does not implement public int 
available() throws IOException
                 Key: COMPRESS-255
                 URL: https://issues.apache.org/jira/browse/COMPRESS-255
             Project: Commons Compress
          Issue Type: Bug
          Components: Compressors
    Affects Versions: 1.6
         Environment: Java
            Reporter: Kevin Dauch


Here is the patch that I created:
--- 
src/main/java/org/apache/commons/compress/compressors/bzip2/BZip2CompressorInputStream.java
 (revision 1550240)
+++ 
src/main/java/org/apache/commons/compress/compressors/bzip2/BZip2CompressorInputStream.java
 (working copy)
@@ -147,6 +147,16 @@
         }
     }
 
+    @Override
+    public int available() throws IOException {
+       int avail = 0;
+       if (this.in != null) {
+           avail = this.in.available();
+       }
+        return avail;
+    }
+
+
     /*
      * (non-Javadoc)
      * 




--
This message was sent by Atlassian JIRA
(v6.1.5#6160)

Reply via email to