209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
|
} @catch (OFOpenItemFailedException *e) {
[of_stderr writeFormat: @"Failed to open file %@: %s\n",
[e path], strerror([e errNo])];
[OFApplication terminateWithStatus: 1];
}
@try {
if ([path hasSuffix: @".gz"])
archive = [GZIPArchive archiveWithFile: file];
else
archive = [ZIPArchive archiveWithFile: file];
} @catch (OFReadFailedException *e) {
[of_stderr writeFormat: @"Failed to read file %@: %s\n",
path, strerror([e errNo])];
[OFApplication terminateWithStatus: 1];
|
|
|
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
|
} @catch (OFOpenItemFailedException *e) {
[of_stderr writeFormat: @"Failed to open file %@: %s\n",
[e path], strerror([e errNo])];
[OFApplication terminateWithStatus: 1];
}
@try {
if ([path hasSuffix: @".gz"] || [path hasSuffix: @".GZ"])
archive = [GZIPArchive archiveWithFile: file];
else
archive = [ZIPArchive archiveWithFile: file];
} @catch (OFReadFailedException *e) {
[of_stderr writeFormat: @"Failed to read file %@: %s\n",
path, strerror([e errNo])];
[OFApplication terminateWithStatus: 1];
|