Fixed zip archive method definition
This commit is contained in:
@@ -91,6 +91,7 @@ typedef NS_ENUM(NSInteger, SSZipArchiveErrorCode) {
|
||||
|
||||
// with optional password, default encryption is AES
|
||||
// don't use AES if you need compatibility with native macOS unzip and Archive Utility
|
||||
+ (BOOL)createZipFileAtPath:(NSString *)path withFilesAtPaths:(NSArray<NSString *> *)paths diskSize:(int)diskSize;
|
||||
+ (BOOL)createZipFileAtPath:(NSString *)path withFilesAtPaths:(NSArray<NSString *> *)paths withPassword:(nullable NSString *)password;
|
||||
+ (BOOL)createZipFileAtPath:(NSString *)path withContentsOfDirectory:(NSString *)directoryPath withPassword:(nullable NSString *)password;
|
||||
+ (BOOL)createZipFileAtPath:(NSString *)path withContentsOfDirectory:(NSString *)directoryPath keepParentDirectory:(BOOL)keepParentDirectory withPassword:(nullable NSString *)password;
|
||||
|
||||
@@ -673,7 +673,7 @@ BOOL _fileIsSymbolicLink(const unz_file_info *fileInfo);
|
||||
BOOL success = [zipArchive openWithSplitSize:diskSize];
|
||||
if (success) {
|
||||
for (NSString *filePath in paths) {
|
||||
success &= [zipArchive writeFile:filePath withPassword:password];
|
||||
success &= [zipArchive writeFile:filePath withPassword:nil];
|
||||
}
|
||||
success &= [zipArchive close];
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user