Java version "1.8.0_40"
Java(TM) SE Runtime Environment (build 1.8.0_40-b26)
I am using core java.util.zip
classes. Now while unzipping a client file using this code:
public static InputStream unzip(String file,InputStream zip)
throws IOException {
file = file.toLowerCase();
ZipInputStream zin = new ZipInputStream(new BufferedInputStream(zip));
ZipEntry ze;
while( (ze = zin.getNextEntry()) != null ) {
if ( ze.getName().toLowerCase().equals(file) )
return zin;
}
throw new RuntimeException(file+" not found in zip");
}
I am getting following error:
invalid entry size (expected 1355916815 but got 5650884111 bytes)
However the same code works fine in JDK 1.6.
I searched for all day but unable to find any occurrence that there are any changes corresponding to this code in Java JDK.
Please help me find suitable cause or links to support my findings.