java.util.zip.zipException:未知的压缩方法
我正在使用第三方 API http://jortho.sourceforge.net/ 在使用API时,我总是遇到异常
java.util.zip.zipexception : unknown compression method
There are no zip filesvolved,我尝试不使用API的.jar文件,而是直接使用类文件,但它仍然给我同样的错误。
可能是什么原因?我如何开始调试? 有一个类 WordIterator 使用 java.util.zip.InflaterInputStream 但我不认为问题出在 API 上。
我被困住了!可能的出路是什么?
I am working with a third party API http://jortho.sourceforge.net/
While using the API, I always get an exception
java.util.zip.zipexception : unknown compression method
There are no zip files involved, I tried not using the .jar file of the API, instead using the class files directly, but it still gives me the same error.
What possibly could be the reason? How can I start off with my debugging?
There is a class WordIterator which uses java.util.zip.InflaterInputStream
but I don't think the problem is with the API.
I am stuck! What can be the possible way out?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
我听起来好像有人试图解压缩损坏的 zip 文件/流,或者根本不是 zip 文件或流的东西。
由于 JOrtho 是 GPL,因此您最好的办法是获取源代码并自行调试。在 Eclipse 中,您可以在 ZipException 上设置异常断点,调试器将在引发异常之前立即停止。
I sounds to me as if someone is trying to unzip a corrupted zip-file/stream, or something which isn't a zip-file or stream at all.
Since JOrtho is GPL, your best shot is to get the source code and debug the thing yourself. In Eclipse, you can set an exception breakpoint on
ZipException
and the debugger will stop immediately before the exception is thrown.