Differences From Artifact [78d0532385]:
- File src/OFData.m — part of check-in [526feacebc] at 2017-11-11 23:27:09 on branch trunk — Small optimization for -[isEqual:] (user: js, size: 12431) [annotate] [blame] [check-ins using]
To Artifact [995d1dfd33]:
- File
src/OFData.m
— part of check-in
[34fe205b84]
at
2017-11-12 18:27:56
on branch trunk
— OFFileManager: Major API redesign
This removes all query methods and replaces them by a single one that
returns a dictionary. Not only does this allow querying multiple
attributes at once, it is also more extensible, as the previous
attributes were specific to file URLs. (user: js, size: 12423) [annotate] [blame] [check-ins using]
︙ | ︙ | |||
189 190 191 192 193 194 195 | return self; } #ifdef OF_HAVE_FILES - (instancetype)initWithContentsOfFile: (OFString *)path { @try { | | | | | > | 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 | return self; } #ifdef OF_HAVE_FILES - (instancetype)initWithContentsOfFile: (OFString *)path { @try { uintmax_t size = [[[OFFileManager defaultManager] attributesOfItemAtPath: path] fileSize]; char *buffer; # if UINTMAX_MAX > SIZE_MAX if (size > SIZE_MAX) @throw [OFOutOfRangeException exception]; # endif buffer = malloc((size_t)size); if (buffer == NULL) @throw [OFOutOfMemoryException exceptionWithRequestedSize: (size_t)size]; @try { |
︙ | ︙ |