Differences From Artifact [cefb3af267]:
- File
utils/ofarc/ZIPArchive.m
— part of check-in
[b01c12cecd]
at
2022-10-30 18:30:51
on branch trunk
— utils/ofarc: Remove pointless range check
The range check was a leftover from when different types were used. (user: js, size: 13238) [annotate] [blame] [check-ins using] [more...]
To Artifact [110299511c]:
- File utils/ofarc/ZIPArchive.m — part of check-in [8939cbdb52] at 2023-01-06 09:04:02 on branch trunk — Update copyright (user: js, size: 13388) [annotate] [blame] [check-ins using] [more...]
1 | /* | | | 1 2 3 4 5 6 7 8 9 | /* * Copyright (c) 2008-2023 Jonathan Schleifer <js@nil.im> * * All rights reserved. * * This file is part of ObjFW. It may be distributed under the terms of the * Q Public License 1.0, which can be found in the file LICENSE.QPL included in * the packaging of this file. * |
︙ | ︙ | |||
29 30 31 32 33 34 35 36 37 38 39 40 41 42 | #import "ZIPArchive.h" #import "OFArc.h" #import "OFInvalidFormatException.h" #import "OFOpenItemFailedException.h" #import "OFOutOfRangeException.h" static OFArc *app; static void setPermissions(OFString *path, OFZIPArchiveEntry *entry) { #ifdef OF_FILE_MANAGER_SUPPORTS_PERMISSIONS | > | 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 | #import "ZIPArchive.h" #import "OFArc.h" #import "OFInvalidFormatException.h" #import "OFOpenItemFailedException.h" #import "OFOutOfRangeException.h" #import "OFSetItemAttributesFailedException.h" static OFArc *app; static void setPermissions(OFString *path, OFZIPArchiveEntry *entry) { #ifdef OF_FILE_MANAGER_SUPPORTS_PERMISSIONS |
︙ | ︙ | |||
62 63 64 65 66 67 68 | if (modificationDate == nil) return; attributes = [OFDictionary dictionaryWithObject: modificationDate forKey: OFFileModificationDate]; | > | | > > > > | 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 | if (modificationDate == nil) return; attributes = [OFDictionary dictionaryWithObject: modificationDate forKey: OFFileModificationDate]; @try { [[OFFileManager defaultManager] setAttributes: attributes ofItemAtPath: path]; } @catch (OFSetItemAttributesFailedException *e) { if (e.errNo != EISDIR) @throw e; } } @implementation ZIPArchive + (void)initialize { if (self == [ZIPArchive class]) app = (OFArc *)[OFApplication sharedApplication].delegate; |
︙ | ︙ |