我使用来自github的Objective-Zip - https://github.com/flyingdolphinstudio/Objective-Zip 如果zip文件坏了我有这个:
Terminating app due to uncaught exception 'ZipException', reason: 'Can't open
之后app崩溃了。 如何得到错误,但程序没有下降?
答案 0 :(得分:1)
简单地抓住例外:
@try {
// Zip code here
}
@catch (ZipException *exception) {
// Error happened, do whatever you need
}