java.util.zip.ZipError: invalid CEN header (bad signature)

前端 未结 5 1495
佛祖请我去吃肉
佛祖请我去吃肉 2021-01-11 10:23

I\'m using Java 1.7.0_40 on Red Hat Linux and I have the following code:

Path zipfile = Paths.get(filename);
FileSystem fs = FileSystems.newFileSystem(zipfil         


        
5条回答
  •  半阙折子戏
    2021-01-11 10:54

    Large file (4GB+) support for zip archives (i.e. 64-bit zip support) was addressed by issue JDK-4681995 ("Add support for large (> 4GB) zip/jar files").

    However, this change was not included in Java 7 until 1.7.0 build 55, which was a few builds after the specific version (1.7.0 build 40) that you were using. Updating to build 55 or later would solve the problem.

提交回复
热议问题