Differences From Artifact [b1663cc4e4]:
- File
src/OFFileManager.m
— part of check-in
[08fd4dc3bf]
at
2017-11-12 19:00:12
on branch trunk
— OFFileManager: Make all URL methods available
Methods dealing with URLs should not be unavailable just because the
local file system / operating system does not support them. (user: js, size: 41969) [annotate] [blame] [check-ins using]
To Artifact [344a7c8de0]:
- File src/OFFileManager.m — part of check-in [9db4db82ed] at 2017-11-12 21:42:03 on branch trunk — OFFileManager: Symlinks take a destination path (user: js, size: 41705) [annotate] [blame] [check-ins using]
︙ | ︙ | |||
612 613 614 615 616 617 618 | # endif @throw [OFSetItemAttributesFailedException exceptionWithPath: path attributes: attributes failedAttribute: of_file_attribute_key_posix_permissions errNo: errno]; #else | | < | 612 613 614 615 616 617 618 619 620 621 622 623 624 625 626 | # endif @throw [OFSetItemAttributesFailedException exceptionWithPath: path attributes: attributes failedAttribute: of_file_attribute_key_posix_permissions errNo: errno]; #else OF_UNRECOGNIZED_SELECTOR #endif } - (void)of_setOwner: (OFString *)owner andGroup: (OFString *)group ofItemAtPath: (OFString *)path attributeKey: (of_file_attribute_key_t)attributeKey |
︙ | ︙ | |||
677 678 679 680 681 682 683 | if (chown([path cStringWithEncoding: encoding], uid, gid) != 0) @throw [OFSetItemAttributesFailedException exceptionWithPath: path attributes: attributes failedAttribute: attributeKey errNo: errno]; #else | | < | 676 677 678 679 680 681 682 683 684 685 686 687 688 689 690 | if (chown([path cStringWithEncoding: encoding], uid, gid) != 0) @throw [OFSetItemAttributesFailedException exceptionWithPath: path attributes: attributes failedAttribute: attributeKey errNo: errno]; #else OF_UNRECOGNIZED_SELECTOR #endif } - (void)setAttributes: (of_file_attributes_t)attributes ofItemAtPath: (OFString *)path { void *pool; |
︙ | ︙ | |||
1579 1580 1581 1582 1583 1584 1585 | void *pool = objc_autoreleasePoolPush(); [self linkItemAtPath: [source fileSystemRepresentation] toPath: [destination fileSystemRepresentation]]; objc_autoreleasePoolPop(pool); #else | | < | 1577 1578 1579 1580 1581 1582 1583 1584 1585 1586 1587 1588 1589 1590 1591 | void *pool = objc_autoreleasePoolPush(); [self linkItemAtPath: [source fileSystemRepresentation] toPath: [destination fileSystemRepresentation]]; objc_autoreleasePoolPop(pool); #else OF_UNRECOGNIZED_SELECTOR #endif } #ifdef OF_FILE_MANAGER_SUPPORTS_SYMLINKS - (void)createSymbolicLinkAtPath: (OFString *)destination withDestinationPath: (OFString *)source { |
︙ | ︙ | |||
1622 1623 1624 1625 1626 1627 1628 | # endif objc_autoreleasePoolPop(pool); } #endif - (void)createSymbolicLinkAtURL: (OFURL *)destination | | | | < | 1619 1620 1621 1622 1623 1624 1625 1626 1627 1628 1629 1630 1631 1632 1633 1634 1635 1636 1637 1638 1639 1640 1641 1642 1643 | # endif objc_autoreleasePoolPop(pool); } #endif - (void)createSymbolicLinkAtURL: (OFURL *)destination withDestinationPath: (OFString *)source { #ifdef OF_FILE_MANAGER_SUPPORTS_SYMLINKS void *pool = objc_autoreleasePoolPush(); [self createSymbolicLinkAtPath: [destination fileSystemRepresentation] withDestinationPath: source]; objc_autoreleasePoolPop(pool); #else OF_UNRECOGNIZED_SELECTOR #endif } @end @implementation OFDictionary (FileAttributes) - (uintmax_t)fileSize { |
︙ | ︙ |