Comment: | Merge branch 'master' into 1.0 |
---|---|
Downloads: | Tarball | ZIP archive | SQL archive |
Timelines: | family | ancestors | descendants | both | 1.0 |
Files: | files | file ages | folders |
SHA3-256: |
76245b46658341cc8d9848a1bffc5c11 |
User & Date: | js on 2019-09-29 19:57:03 |
Other Links: | branch diff | manifest | tags |
2019-12-15
| ||
15:37 | Merge branch 'master' into 1.0 check-in: 11e303eb3b user: js tags: 1.0 | |
2019-09-29
| ||
19:57 | Merge branch 'master' into 1.0 check-in: 76245b4665 user: js tags: 1.0 | |
19:48 | Documentation fixes check-in: 3be624ded9 user: js tags: trunk | |
15:25 | Remove incomplete -[OFInvocation invoke] support check-in: fc521f01cc user: js tags: 1.0 | |
Modified configure.ac from [f548d853f6] to [d5db25efd9].
︙ | ︙ | |||
1449 1450 1451 1452 1453 1454 1455 | AC_CHECK_FUNC(pledge, [ AC_DEFINE(OF_HAVE_PLEDGE, 1, [Whether we have pledge()]) ]) AS_IF([test x"$objc_runtime" = x"Apple runtime"], [ AC_CHECK_HEADER(Foundation/NSObject.h, [ | < | 1449 1450 1451 1452 1453 1454 1455 1456 1457 1458 1459 1460 1461 1462 | AC_CHECK_FUNC(pledge, [ AC_DEFINE(OF_HAVE_PLEDGE, 1, [Whether we have pledge()]) ]) AS_IF([test x"$objc_runtime" = x"Apple runtime"], [ AC_CHECK_HEADER(Foundation/NSObject.h, [ AC_SUBST(BRIDGE, "bridge") AS_IF([test x"$enable_shared" != x"no"], [ AC_SUBST(OBJFWBRIDGE_SHARED_LIB, "${LIB_PREFIX}objfwbridge${LIB_SUFFIX}") ]) AS_IF([test x"$enable_static" = x"yes" \ |
︙ | ︙ |
Modified extra.mk.in from [4b6a84413a] to [c2430594e6].
︙ | ︙ | |||
32 33 34 35 36 37 38 | EXCEPTIONS_EXCEPTIONS_A = @EXCEPTIONS_EXCEPTIONS_A@ EXCEPTIONS_EXCEPTIONS_LIB_A = @EXCEPTIONS_EXCEPTIONS_LIB_A@ EXCEPTIONS_LIB_A = @EXCEPTIONS_LIB_A@ FORWARDING_A = @FORWARDING_A@ FORWARDING_FORWARDING_A = @FORWARDING_FORWARDING_A@ FORWARDING_FORWARDING_LIB_A = @FORWARDING_FORWARDING_LIB_A@ FORWARDING_LIB_A = @FORWARDING_LIB_A@ | < | 32 33 34 35 36 37 38 39 40 41 42 43 44 45 | EXCEPTIONS_EXCEPTIONS_A = @EXCEPTIONS_EXCEPTIONS_A@ EXCEPTIONS_EXCEPTIONS_LIB_A = @EXCEPTIONS_EXCEPTIONS_LIB_A@ EXCEPTIONS_LIB_A = @EXCEPTIONS_LIB_A@ FORWARDING_A = @FORWARDING_A@ FORWARDING_FORWARDING_A = @FORWARDING_FORWARDING_A@ FORWARDING_FORWARDING_LIB_A = @FORWARDING_FORWARDING_LIB_A@ FORWARDING_LIB_A = @FORWARDING_LIB_A@ INSTANCE_M = @INSTANCE_M@ INVOCATION_A = @INVOCATION_A@ INVOCATION_INVOCATION_A = @INVOCATION_INVOCATION_A@ INVOCATION_INVOCATION_LIB_A = @INVOCATION_INVOCATION_LIB_A@ INVOCATION_LIB_A = @INVOCATION_LIB_A@ LIBBASES_M = @LIBBASES_M@ LIBOBJFWRT_DEP = @LIBOBJFWRT_DEP@ |
︙ | ︙ |
Modified src/Makefile from [d469306a05] to [04a46c14e4].
︙ | ︙ | |||
8 9 10 11 12 13 14 | STATIC_LIB = ${OBJFW_STATIC_LIB} FRAMEWORK = ${OBJFW_FRAMEWORK} LIB_MAJOR = ${OBJFW_LIB_MAJOR} LIB_MINOR = ${OBJFW_LIB_MINOR} SRCS = OFApplication.m \ OFArray.m \ | < | 8 9 10 11 12 13 14 15 16 17 18 19 20 21 | STATIC_LIB = ${OBJFW_STATIC_LIB} FRAMEWORK = ${OBJFW_FRAMEWORK} LIB_MAJOR = ${OBJFW_LIB_MAJOR} LIB_MINOR = ${OBJFW_LIB_MINOR} SRCS = OFApplication.m \ OFArray.m \ OFBlock.m \ OFCharacterSet.m \ OFColor.m \ OFConstantString.m \ OFCountedSet.m \ OFData.m \ OFData+CryptoHashing.m \ |
︙ | ︙ | |||
192 193 194 195 196 197 198 | OFPointerValue.m \ OFRangeCharacterSet.m \ OFRangeValue.m \ OFRectangleValue.m \ OFSubarray.m \ OFUTF8String.m \ ${AUTORELEASE_M} \ | < | 191 192 193 194 195 196 197 198 199 200 201 202 203 204 | OFPointerValue.m \ OFRangeCharacterSet.m \ OFRangeValue.m \ OFRectangleValue.m \ OFSubarray.m \ OFUTF8String.m \ ${AUTORELEASE_M} \ ${INSTANCE_M} \ ${LIBBASES_M} SRCS_FILES += OFFileURLHandler.m \ OFINIFileSettings.m SRCS_SOCKETS += OFHTTPURLHandler.m \ OFKernelEventObserver.m \ ${OFEPOLLKERNELEVENTOBSERVER_M} \ |
︙ | ︙ |
Modified src/OFAdjacentArray.h from [6f24e09a18] to [cebe5ad233].
︙ | ︙ | |||
17 18 19 20 21 22 23 24 25 26 27 28 29 30 | #import "OFArray.h" OF_ASSUME_NONNULL_BEGIN @class OFMutableData; @interface OFAdjacentArray: OFArray { OFMutableData *_array; } @end OF_ASSUME_NONNULL_END | > | 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 | #import "OFArray.h" OF_ASSUME_NONNULL_BEGIN @class OFMutableData; OF_SUBCLASSING_RESTRICTED @interface OFAdjacentArray: OFArray { OFMutableData *_array; } @end OF_ASSUME_NONNULL_END |
Modified src/OFAdjacentSubarray.h from [089d0764c2] to [bd17bec51a].
︙ | ︙ | |||
15 16 17 18 19 20 21 22 23 24 25 | * file. */ #import "OFSubarray.h" OF_ASSUME_NONNULL_BEGIN @interface OFAdjacentSubarray: OFSubarray @end OF_ASSUME_NONNULL_END | > | 15 16 17 18 19 20 21 22 23 24 25 26 | * file. */ #import "OFSubarray.h" OF_ASSUME_NONNULL_BEGIN OF_SUBCLASSING_RESTRICTED @interface OFAdjacentSubarray: OFSubarray @end OF_ASSUME_NONNULL_END |
Modified src/OFApplication.h from [b018d35a5c] to [93b516bfa0].
︙ | ︙ | |||
40 41 42 43 44 45 46 47 48 49 50 51 52 53 | # define OF_HAVE_SANDBOX #endif /*! * @protocol OFApplicationDelegate OFApplication.h ObjFW/OFApplication.h * * @brief A protocol for delegates of OFApplication. */ @protocol OFApplicationDelegate <OFObject> /*! * @brief A method which is called when the application was initialized and is * running now. */ - (void)applicationDidFinishLaunching; | > > | 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 | # define OF_HAVE_SANDBOX #endif /*! * @protocol OFApplicationDelegate OFApplication.h ObjFW/OFApplication.h * * @brief A protocol for delegates of OFApplication. * * @note Signals are not available on AmigaOS! */ @protocol OFApplicationDelegate <OFObject> /*! * @brief A method which is called when the application was initialized and is * running now. */ - (void)applicationDidFinishLaunching; |
︙ | ︙ | |||
116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 | * * @brief A class which represents the application as an object. * * In order to create a new OFApplication, you should create a class conforming * to the optional @ref OFApplicationDelegate protocol and put * `OF_APPLICATION_DELEGATE(NameOfYourClass)` in the .m file of that class. */ @interface OFApplication: OFObject { OFString *_programName; OFArray OF_GENERIC(OFString *) *_arguments; OFMutableDictionary OF_GENERIC(OFString *, OFString *) *_environment; int *_argc; char ***_argv; #ifdef OF_APPLICATION_M @public #endif id <OFApplicationDelegate> _Nullable _delegate; void (*_Nullable _SIGINTHandler)(id, SEL); #ifndef OF_WINDOWS void (*_Nullable _SIGHUPHandler)(id, SEL); void (*_Nullable _SIGUSR1Handler)(id, SEL); void (*_Nullable _SIGUSR2Handler)(id, SEL); #endif #ifdef OF_HAVE_SANDBOX | > | > | 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 | * * @brief A class which represents the application as an object. * * In order to create a new OFApplication, you should create a class conforming * to the optional @ref OFApplicationDelegate protocol and put * `OF_APPLICATION_DELEGATE(NameOfYourClass)` in the .m file of that class. */ OF_SUBCLASSING_RESTRICTED @interface OFApplication: OFObject { OFString *_programName; OFArray OF_GENERIC(OFString *) *_arguments; OFMutableDictionary OF_GENERIC(OFString *, OFString *) *_environment; int *_argc; char ***_argv; #ifdef OF_APPLICATION_M @public #endif id <OFApplicationDelegate> _Nullable _delegate; void (*_Nullable _SIGINTHandler)(id, SEL); #ifndef OF_WINDOWS void (*_Nullable _SIGHUPHandler)(id, SEL); void (*_Nullable _SIGUSR1Handler)(id, SEL); void (*_Nullable _SIGUSR2Handler)(id, SEL); #endif #ifdef OF_HAVE_SANDBOX OFSandbox *_Nullable _activeSandbox; OFSandbox *_Nullable _activeSandboxForChildProcesses; #endif } #ifdef OF_HAVE_CLASS_PROPERTIES @property (class, readonly, nullable, nonatomic) OFApplication *sharedApplication; @property (class, readonly, nullable, nonatomic) OFString *programName; |
︙ | ︙ | |||
177 178 179 180 181 182 183 | #ifdef OF_HAVE_SANDBOX /*! * @brief The sandbox currently active for this application. */ @property OF_NULLABLE_PROPERTY (readonly, nonatomic) OFSandbox *activeSandbox; /*! | | < | | 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 | #ifdef OF_HAVE_SANDBOX /*! * @brief The sandbox currently active for this application. */ @property OF_NULLABLE_PROPERTY (readonly, nonatomic) OFSandbox *activeSandbox; /*! * @brief The sandbox currently active for child processes of this application. */ @property OF_NULLABLE_PROPERTY (readonly, nonatomic) OFSandbox *activeSandboxForChildProcesses; #endif /*! * @brief Returns the only OFApplication instance in the application. * * @return The only OFApplication instance in the application */ |
︙ | ︙ | |||
231 232 233 234 235 236 237 | #ifdef OF_HAVE_SANDBOX /*! * @brief Activates the specified sandbox for the application. * * This is only available if `OF_HAVE_SANDBOX` is defined. * * @warning If you allow `exec()`, but do not call | | | | | | 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 | #ifdef OF_HAVE_SANDBOX /*! * @brief Activates the specified sandbox for the application. * * This is only available if `OF_HAVE_SANDBOX` is defined. * * @warning If you allow `exec()`, but do not call * @ref activateSandboxForChildProcesses:, an `exec()`'d process does * not have its permissions restricted! * * @note Once a sandbox has been activated, you cannot activate a different * sandbox. You can however change the active sandbox and reactivate it. * * @param sandbox The sandbox to activate */ + (void)activateSandbox: (OFSandbox *)sandbox; /*! * @brief Activates the specified sandbox for child processes of the * application. * * This is only available if `OF_HAVE_SANDBOX` is defined. * * `unveiledPaths` on the sandbox must *not* be empty, otherwise an * @ref OFInvalidArgumentException is raised. * * @note Once a sandbox has been activated, you cannot activate a different * sandbox. You can however change the active sandbox and reactivate it. * * @param sandbox The sandbox to activate */ + (void)activateSandboxForChildProcesses: (OFSandbox *)sandbox; #endif - (instancetype)init OF_UNAVAILABLE; /*! * @brief Gets argc and argv. * |
︙ | ︙ | |||
288 289 290 291 292 293 294 | #ifdef OF_HAVE_SANDBOX /*! * @brief Activates the specified sandbox for the application. * * This is only available if `OF_HAVE_SANDBOX` is defined. * * @warning If you allow `exec()`, but do not call | | | | | | 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 306 307 308 309 310 311 312 313 314 315 316 317 318 319 320 321 322 323 324 325 326 327 328 329 330 331 332 333 334 335 | #ifdef OF_HAVE_SANDBOX /*! * @brief Activates the specified sandbox for the application. * * This is only available if `OF_HAVE_SANDBOX` is defined. * * @warning If you allow `exec()`, but do not call * @ref activateSandboxForChildProcesses:, an `exec()`'d process does * not have its permissions restricted! * * @note Once a sandbox has been activated, you cannot activate a different * sandbox. You can however change the active sandbox and reactivate it. * * @param sandbox The sandbox to activate */ - (void)activateSandbox: (OFSandbox *)sandbox; /*! * @brief Activates the specified sandbox for child processes of the * application. * * This is only available if `OF_HAVE_SANDBOX` is defined. * * `unveiledPaths` on the sandbox must *not* be empty, otherwise an * @ref OFInvalidArgumentException is raised. * * @note Once a sandbox has been activated, you cannot activate a different * sandbox. You can however change the active sandbox and reactivate it. * * @param sandbox The sandbox to activate */ - (void)activateSandboxForChildProcesses: (OFSandbox *)sandbox; #endif @end #ifdef __cplusplus extern "C" { #endif extern int of_application_main(int *_Nonnull, char *_Nullable *_Nonnull[_Nonnull], id <OFApplicationDelegate>); #ifdef __cplusplus } #endif OF_ASSUME_NONNULL_END |
Modified src/OFApplication.m from [0eab530ffc] to [c0cd7cc60a].
︙ | ︙ | |||
152 153 154 155 156 157 158 | } @implementation OFApplication @synthesize programName = _programName, arguments = _arguments; @synthesize environment = _environment; #ifdef OF_HAVE_SANDBOX @synthesize activeSandbox = _activeSandbox; | | | 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 | } @implementation OFApplication @synthesize programName = _programName, arguments = _arguments; @synthesize environment = _environment; #ifdef OF_HAVE_SANDBOX @synthesize activeSandbox = _activeSandbox; @synthesize activeSandboxForChildProcesses = _activeSandboxForChildProcesses; #endif + (OFApplication *)sharedApplication { return app; } |
︙ | ︙ | |||
201 202 203 204 205 206 207 | #ifdef OF_HAVE_SANDBOX + (void)activateSandbox: (OFSandbox *)sandbox { [app activateSandbox: sandbox]; } | | | | 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 | #ifdef OF_HAVE_SANDBOX + (void)activateSandbox: (OFSandbox *)sandbox { [app activateSandbox: sandbox]; } + (void)activateSandboxForChildProcesses: (OFSandbox *)sandbox { [app activateSandboxForChildProcesses: sandbox]; } #endif - (instancetype)init { OF_INVALID_INIT_METHOD } |
︙ | ︙ | |||
626 627 628 629 630 631 632 | objc_autoreleasePoolPop(pool); if (_activeSandbox == nil) _activeSandbox = [sandbox retain]; # endif } | | > | | | | 626 627 628 629 630 631 632 633 634 635 636 637 638 639 640 641 642 643 644 645 646 647 648 649 650 651 652 653 654 655 656 657 658 659 660 661 | objc_autoreleasePoolPop(pool); if (_activeSandbox == nil) _activeSandbox = [sandbox retain]; # endif } - (void)activateSandboxForChildProcesses: (OFSandbox *)sandbox { # ifdef OF_HAVE_PLEDGE void *pool = objc_autoreleasePoolPush(); const char *promises; if (_activeSandboxForChildProcesses != nil && sandbox != _activeSandboxForChildProcesses) @throw [OFInvalidArgumentException exception]; if (sandbox.unveiledPaths.count != 0) @throw [OFInvalidArgumentException exception]; promises = [sandbox.pledgeString cStringWithEncoding: [OFLocale encoding]]; if (pledge(NULL, promises) != 0) @throw [OFSandboxActivationFailedException exceptionWithSandbox: sandbox errNo: errno]; objc_autoreleasePoolPop(pool); if (_activeSandboxForChildProcesses == nil) _activeSandboxForChildProcesses = [sandbox retain]; # endif } #endif @end |
Modified src/OFArray.h from [f7419d3b33] to [72663abff1].
︙ | ︙ | |||
88 89 90 91 92 93 94 95 96 97 98 99 100 101 | * @brief An abstract class for storing objects in an array. * * @note Subclasses must implement @ref count and @ref objectAtIndex:. */ @interface OFArray OF_GENERIC(ObjectType): OFObject <OFCopying, OFMutableCopying, OFCollection, OFSerialization, OFJSONRepresentation, OFMessagePackRepresentation> #if !defined(OF_HAVE_GENERICS) && !defined(DOXYGEN) # define ObjectType id #endif /*! * @brief The objects of the array as a C array. * * The result is valid until the autorelease pool is released. If you want to | > > > > | 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 | * @brief An abstract class for storing objects in an array. * * @note Subclasses must implement @ref count and @ref objectAtIndex:. */ @interface OFArray OF_GENERIC(ObjectType): OFObject <OFCopying, OFMutableCopying, OFCollection, OFSerialization, OFJSONRepresentation, OFMessagePackRepresentation> { OF_RESERVE_IVARS(4) } #if !defined(OF_HAVE_GENERICS) && !defined(DOXYGEN) # define ObjectType id #endif /*! * @brief The objects of the array as a C array. * * The result is valid until the autorelease pool is released. If you want to |
︙ | ︙ |
Deleted src/OFAutoreleasePool+Private.h version [b8bab00634].
|
| < < < < < < < < < < < < < < < < < < < < < < < < < < < |
Deleted src/OFAutoreleasePool.h version [96bdb1482b].
|
| < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < |
Deleted src/OFAutoreleasePool.m version [966b634bbb].
|
| < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < |
Modified src/OFBitSetCharacterSet.h from [354358342b] to [0f5e448e50].
︙ | ︙ | |||
15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 | * file. */ #import "OFCharacterSet.h" OF_ASSUME_NONNULL_BEGIN @interface OFBitSetCharacterSet: OFCharacterSet { unsigned char *_bitset; size_t _size; } @end OF_ASSUME_NONNULL_END | > | 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 | * file. */ #import "OFCharacterSet.h" OF_ASSUME_NONNULL_BEGIN OF_SUBCLASSING_RESTRICTED @interface OFBitSetCharacterSet: OFCharacterSet { unsigned char *_bitset; size_t _size; } @end OF_ASSUME_NONNULL_END |
Modified src/OFBlock.h from [ace9ad8531] to [83c8b8b8fe].
︙ | ︙ | |||
27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 | * @brief The class for all blocks, since all blocks are also objects. */ @interface OFBlock: OFObject + (instancetype)alloc OF_UNAVAILABLE; - (instancetype)init OF_UNAVAILABLE; @end @interface OFStackBlock: OFBlock @end @interface OFGlobalBlock: OFBlock @end @interface OFMallocBlock: OFBlock @end OF_ASSUME_NONNULL_END | > > > | 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 | * @brief The class for all blocks, since all blocks are also objects. */ @interface OFBlock: OFObject + (instancetype)alloc OF_UNAVAILABLE; - (instancetype)init OF_UNAVAILABLE; @end OF_SUBCLASSING_RESTRICTED @interface OFStackBlock: OFBlock @end OF_SUBCLASSING_RESTRICTED @interface OFGlobalBlock: OFBlock @end OF_SUBCLASSING_RESTRICTED @interface OFMallocBlock: OFBlock @end OF_ASSUME_NONNULL_END |
Modified src/OFBytesValue.h from [064f02062a] to [12d8c96477].
︙ | ︙ | |||
15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 | * file. */ #import "OFValue.h" OF_ASSUME_NONNULL_BEGIN @interface OFBytesValue: OFValue { size_t _size; void *_bytes; const char *_objCType; } @end OF_ASSUME_NONNULL_END | > | 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 | * file. */ #import "OFValue.h" OF_ASSUME_NONNULL_BEGIN OF_SUBCLASSING_RESTRICTED @interface OFBytesValue: OFValue { size_t _size; void *_bytes; const char *_objCType; } @end OF_ASSUME_NONNULL_END |
Modified src/OFCharacterSet.h from [f46e129e3b] to [de7fc1853c].
︙ | ︙ | |||
24 25 26 27 28 29 30 31 32 33 34 35 36 37 | * @class OFCharacterSet OFCharacterSet.h ObjFW/OFCharacterSet.h * * @brief A class cluster representing a character set. * * @note Subclasses must implement @ref characterIsMember:. */ @interface OFCharacterSet: OFObject #ifdef OF_HAVE_CLASS_PROPERTIES @property (class, readonly, nonatomic) OFCharacterSet *whitespaceCharacterSet; #endif /*! * @brief The inverted set, containing only the characters that do not exist in * the receiver. | > > > > | 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 | * @class OFCharacterSet OFCharacterSet.h ObjFW/OFCharacterSet.h * * @brief A class cluster representing a character set. * * @note Subclasses must implement @ref characterIsMember:. */ @interface OFCharacterSet: OFObject { OF_RESERVE_IVARS(4) } #ifdef OF_HAVE_CLASS_PROPERTIES @property (class, readonly, nonatomic) OFCharacterSet *whitespaceCharacterSet; #endif /*! * @brief The inverted set, containing only the characters that do not exist in * the receiver. |
︙ | ︙ |
Modified src/OFColor.h from [edab75bee1] to [e931392faa].
︙ | ︙ | |||
23 24 25 26 27 28 29 30 31 32 33 34 35 36 | * @class OFColor OFColor.h ObjFW/OFColor.h * * @brief A class for storing a color. */ @interface OFColor: OFObject { float _red, _green, _blue, _alpha; } /*! * @brief Creates a new color with the specified red, green, blue and alpha * value. * * @param red The red value of the color, between 0.0 and 1.0 | > | 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 | * @class OFColor OFColor.h ObjFW/OFColor.h * * @brief A class for storing a color. */ @interface OFColor: OFObject { float _red, _green, _blue, _alpha; OF_RESERVE_IVARS(4) } /*! * @brief Creates a new color with the specified red, green, blue and alpha * value. * * @param red The red value of the color, between 0.0 and 1.0 |
︙ | ︙ |
Modified src/OFCondition.h from [71a90ae1ff] to [d3391d482d].
︙ | ︙ | |||
24 25 26 27 28 29 30 31 32 33 34 35 36 37 | @class OFDate; /*! * @class OFCondition OFCondition.h ObjFW/OFCondition.h * * @brief A class implementing a condition variable for thread synchronization. */ @interface OFCondition: OFMutex { of_condition_t _condition; bool _conditionInitialized; } /*! | > | 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 | @class OFDate; /*! * @class OFCondition OFCondition.h ObjFW/OFCondition.h * * @brief A class implementing a condition variable for thread synchronization. */ OF_SUBCLASSING_RESTRICTED @interface OFCondition: OFMutex { of_condition_t _condition; bool _conditionInitialized; } /*! |
︙ | ︙ |
Modified src/OFConstantString.h from [1c96b5dc8b] to [c489056f79].
︙ | ︙ | |||
31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 | #endif /*! * @class OFConstantString OFConstantString.h ObjFW/OFConstantString.h * * @brief A class for storing constant strings using the `@""` literal. */ @interface OFConstantString: OFString { char *_cString; unsigned int _cStringLength; } @end OF_ASSUME_NONNULL_END | > | 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 | #endif /*! * @class OFConstantString OFConstantString.h ObjFW/OFConstantString.h * * @brief A class for storing constant strings using the `@""` literal. */ OF_SUBCLASSING_RESTRICTED @interface OFConstantString: OFString { char *_cString; unsigned int _cStringLength; } @end OF_ASSUME_NONNULL_END |
Modified src/OFCountedMapTableSet.h from [425da1187b] to [54cdfe273c].
︙ | ︙ | |||
17 18 19 20 21 22 23 24 25 26 27 28 29 30 | #import "OFCountedSet.h" OF_ASSUME_NONNULL_BEGIN @class OFMapTable; @interface OFCountedMapTableSet: OFCountedSet { OFMapTable *_mapTable; } @end OF_ASSUME_NONNULL_END | > | 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 | #import "OFCountedSet.h" OF_ASSUME_NONNULL_BEGIN @class OFMapTable; OF_SUBCLASSING_RESTRICTED @interface OFCountedMapTableSet: OFCountedSet { OFMapTable *_mapTable; } @end OF_ASSUME_NONNULL_END |
Modified src/OFCountedSet.h from [4abf7110e4] to [2ecebf0177].
︙ | ︙ | |||
44 45 46 47 48 49 50 51 52 53 54 55 56 57 | * of @ref OFSet and @ref OFMutableSet that need to be implemented. */ @interface OFCountedSet OF_GENERIC(ObjectType): OFMutableSet OF_GENERIC(ObjectType) #if !defined(OF_HAVE_GENERICS) && !defined(DOXYGEN) # define ObjectType id #endif /*! * @brief Returns how often the object is in the set. * * @return How often the object is in the set */ - (size_t)countForObject: (ObjectType)object; | > > > > | 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 | * of @ref OFSet and @ref OFMutableSet that need to be implemented. */ @interface OFCountedSet OF_GENERIC(ObjectType): OFMutableSet OF_GENERIC(ObjectType) #if !defined(OF_HAVE_GENERICS) && !defined(DOXYGEN) # define ObjectType id #endif { OF_RESERVE_IVARS(4) } /*! * @brief Returns how often the object is in the set. * * @return How often the object is in the set */ - (size_t)countForObject: (ObjectType)object; |
︙ | ︙ |
Modified src/OFDNSResolver.h from [3356c8f51e] to [7a80eed2c3].
︙ | ︙ | |||
117 118 119 120 121 122 123 124 125 126 127 128 129 130 | * @brief A class for resolving DNS names. * * @note If you change any of the properties, make sure to set * @ref configReloadInterval to 0, as otherwise your changes will be * reverted back to the system configuration on the next periodic config * reload. */ @interface OFDNSResolver: OFObject { OFDictionary OF_GENERIC(OFString *, OFArray OF_GENERIC(OFString *) *) *_staticHosts; OFArray OF_GENERIC(OFString *) *_nameServers; OFString *_Nullable _localDomain; OFArray OF_GENERIC(OFString *) *_searchDomains; | > | 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 | * @brief A class for resolving DNS names. * * @note If you change any of the properties, make sure to set * @ref configReloadInterval to 0, as otherwise your changes will be * reverted back to the system configuration on the next periodic config * reload. */ OF_SUBCLASSING_RESTRICTED @interface OFDNSResolver: OFObject { OFDictionary OF_GENERIC(OFString *, OFArray OF_GENERIC(OFString *) *) *_staticHosts; OFArray OF_GENERIC(OFString *) *_nameServers; OFString *_Nullable _localDomain; OFArray OF_GENERIC(OFString *) *_searchDomains; |
︙ | ︙ |
Modified src/OFDNSResourceRecord.h from [4893d76bc3] to [2ea810b61f].
︙ | ︙ | |||
73 74 75 76 77 78 79 80 81 82 83 84 85 86 | */ @interface OFDNSResourceRecord: OFObject <OFCopying> { OFString *_name; of_dns_resource_record_class_t _recordClass; of_dns_resource_record_type_t _recordType; uint32_t _TTL; } /** * @brief The domain name to which the resource record belongs. */ @property (readonly, nonatomic) OFString *name; | > | 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 | */ @interface OFDNSResourceRecord: OFObject <OFCopying> { OFString *_name; of_dns_resource_record_class_t _recordClass; of_dns_resource_record_type_t _recordType; uint32_t _TTL; OF_RESERVE_IVARS(4) } /** * @brief The domain name to which the resource record belongs. */ @property (readonly, nonatomic) OFString *name; |
︙ | ︙ | |||
117 118 119 120 121 122 123 124 125 126 127 128 129 130 | @end /*! * @class OFADNSResourceRecord OFDNSResourceRecord.h ObjFW/OFDNSResourceRecord.h * * @brief A class representing an A DNS resource record. */ @interface OFADNSResourceRecord: OFDNSResourceRecord { of_socket_address_t _address; } /*! * @brief The IPv4 address of the resource record. | > | 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 | @end /*! * @class OFADNSResourceRecord OFDNSResourceRecord.h ObjFW/OFDNSResourceRecord.h * * @brief A class representing an A DNS resource record. */ OF_SUBCLASSING_RESTRICTED @interface OFADNSResourceRecord: OFDNSResourceRecord { of_socket_address_t _address; } /*! * @brief The IPv4 address of the resource record. |
︙ | ︙ | |||
152 153 154 155 156 157 158 159 160 161 162 163 164 165 | /*! * @class OFAAAADNSResourceRecord \ * OFDNSResourceRecord.h ObjFW/OFDNSResourceRecord.h * * @brief A class represenging a DNS resource record. */ @interface OFAAAADNSResourceRecord: OFDNSResourceRecord { of_socket_address_t _address; } /*! * @brief The IPv6 address of the resource record. | > | 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 | /*! * @class OFAAAADNSResourceRecord \ * OFDNSResourceRecord.h ObjFW/OFDNSResourceRecord.h * * @brief A class represenging a DNS resource record. */ OF_SUBCLASSING_RESTRICTED @interface OFAAAADNSResourceRecord: OFDNSResourceRecord { of_socket_address_t _address; } /*! * @brief The IPv6 address of the resource record. |
︙ | ︙ | |||
187 188 189 190 191 192 193 194 195 196 197 198 199 200 | /*! * @class OFCNAMEDNSResourceRecord \ * OFDNSResourceRecord.h ObjFW/OFDNSResourceRecord.h * * @brief A class representing a CNAME DNS resource record. */ @interface OFCNAMEDNSResourceRecord: OFDNSResourceRecord { OFString *_alias; } /*! * @brief The alias of the resource record. | > | 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 | /*! * @class OFCNAMEDNSResourceRecord \ * OFDNSResourceRecord.h ObjFW/OFDNSResourceRecord.h * * @brief A class representing a CNAME DNS resource record. */ OF_SUBCLASSING_RESTRICTED @interface OFCNAMEDNSResourceRecord: OFDNSResourceRecord { OFString *_alias; } /*! * @brief The alias of the resource record. |
︙ | ︙ | |||
224 225 226 227 228 229 230 231 232 233 234 235 236 237 | /*! * @class OFHINFODNSResourceRecord \ * OFDNSResourceRecord.h ObjFW/OFDNSResourceRecord.h * * @brief A class representing an HINFO DNS resource record. */ @interface OFHINFODNSResourceRecord: OFDNSResourceRecord { OFString *_CPU, *_OS; } /*! * @brief The CPU of the host info of the resource record. | > | 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 | /*! * @class OFHINFODNSResourceRecord \ * OFDNSResourceRecord.h ObjFW/OFDNSResourceRecord.h * * @brief A class representing an HINFO DNS resource record. */ OF_SUBCLASSING_RESTRICTED @interface OFHINFODNSResourceRecord: OFDNSResourceRecord { OFString *_CPU, *_OS; } /*! * @brief The CPU of the host info of the resource record. |
︙ | ︙ | |||
268 269 270 271 272 273 274 275 276 277 278 279 280 281 | /*! * @class OFMXDNSResourceRecord \ * OFDNSResourceRecord.h ObjFW/OFDNSResourceRecord.h * * @brief A class representing an MX DNS resource record. */ @interface OFMXDNSResourceRecord: OFDNSResourceRecord { uint16_t _preference; OFString *_mailExchange; } /*! | > | 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 | /*! * @class OFMXDNSResourceRecord \ * OFDNSResourceRecord.h ObjFW/OFDNSResourceRecord.h * * @brief A class representing an MX DNS resource record. */ OF_SUBCLASSING_RESTRICTED @interface OFMXDNSResourceRecord: OFDNSResourceRecord { uint16_t _preference; OFString *_mailExchange; } /*! |
︙ | ︙ | |||
313 314 315 316 317 318 319 320 321 322 323 324 325 326 | /*! * @class OFNSDNSResourceRecord \ * OFDNSResourceRecord.h ObjFW/OFDNSResourceRecord.h * * @brief A class representing an NS DNS resource record. */ @interface OFNSDNSResourceRecord: OFDNSResourceRecord { OFString *_authoritativeHost; } /*! * @brief The authoritative host of the resource record. | > | 319 320 321 322 323 324 325 326 327 328 329 330 331 332 333 | /*! * @class OFNSDNSResourceRecord \ * OFDNSResourceRecord.h ObjFW/OFDNSResourceRecord.h * * @brief A class representing an NS DNS resource record. */ OF_SUBCLASSING_RESTRICTED @interface OFNSDNSResourceRecord: OFDNSResourceRecord { OFString *_authoritativeHost; } /*! * @brief The authoritative host of the resource record. |
︙ | ︙ | |||
350 351 352 353 354 355 356 357 358 359 360 361 362 363 | /*! * @class OFPTRDNSResourceRecord \ * OFDNSResourceRecord.h ObjFW/OFDNSResourceRecord.h * * @brief A class representing a PTR DNS resource record. */ @interface OFPTRDNSResourceRecord: OFDNSResourceRecord { OFString *_domainName; } /*! * @brief The domain name of the resource record. | > | 357 358 359 360 361 362 363 364 365 366 367 368 369 370 371 | /*! * @class OFPTRDNSResourceRecord \ * OFDNSResourceRecord.h ObjFW/OFDNSResourceRecord.h * * @brief A class representing a PTR DNS resource record. */ OF_SUBCLASSING_RESTRICTED @interface OFPTRDNSResourceRecord: OFDNSResourceRecord { OFString *_domainName; } /*! * @brief The domain name of the resource record. |
︙ | ︙ | |||
387 388 389 390 391 392 393 394 395 396 397 398 399 400 | /*! * @class OFRPNSResourceRecord \ * OFDNSResourceRecord.h ObjFW/OFDNSResourceRecord.h * * @brief A class representing an RP DNS resource record. */ @interface OFRPDNSResourceRecord: OFDNSResourceRecord { OFString *_mailbox, *_TXTDomainName; } /*! * @brief The mailbox of the responsible person of the resource record. | > | 395 396 397 398 399 400 401 402 403 404 405 406 407 408 409 | /*! * @class OFRPNSResourceRecord \ * OFDNSResourceRecord.h ObjFW/OFDNSResourceRecord.h * * @brief A class representing an RP DNS resource record. */ OF_SUBCLASSING_RESTRICTED @interface OFRPDNSResourceRecord: OFDNSResourceRecord { OFString *_mailbox, *_TXTDomainName; } /*! * @brief The mailbox of the responsible person of the resource record. |
︙ | ︙ | |||
433 434 435 436 437 438 439 440 441 442 443 444 445 446 | /*! * @class OFSOADNSResourceRecord \ * OFDNSResourceRecord.h ObjFW/OFDNSResourceRecord.h * * @brief A class representing an SOA DNS resource record. */ @interface OFSOADNSResourceRecord: OFDNSResourceRecord { OFString *_primaryNameServer, *_responsiblePerson; uint32_t _serialNumber, _refreshInterval, _retryInterval; uint32_t _expirationInterval, _minTTL; } | > | 442 443 444 445 446 447 448 449 450 451 452 453 454 455 456 | /*! * @class OFSOADNSResourceRecord \ * OFDNSResourceRecord.h ObjFW/OFDNSResourceRecord.h * * @brief A class representing an SOA DNS resource record. */ OF_SUBCLASSING_RESTRICTED @interface OFSOADNSResourceRecord: OFDNSResourceRecord { OFString *_primaryNameServer, *_responsiblePerson; uint32_t _serialNumber, _refreshInterval, _retryInterval; uint32_t _expirationInterval, _minTTL; } |
︙ | ︙ | |||
514 515 516 517 518 519 520 521 522 523 524 525 526 527 | /*! * @class OFSRVDNSResourceRecord \ * OFDNSResourceRecord.h ObjFW/OFDNSResourceRecord.h * * @brief A class representing an SRV DNS resource record. */ @interface OFSRVDNSResourceRecord: OFDNSResourceRecord { uint16_t _priority, _weight; OFString *_target; uint16_t _port; } | > | 524 525 526 527 528 529 530 531 532 533 534 535 536 537 538 | /*! * @class OFSRVDNSResourceRecord \ * OFDNSResourceRecord.h ObjFW/OFDNSResourceRecord.h * * @brief A class representing an SRV DNS resource record. */ OF_SUBCLASSING_RESTRICTED @interface OFSRVDNSResourceRecord: OFDNSResourceRecord { uint16_t _priority, _weight; OFString *_target; uint16_t _port; } |
︙ | ︙ | |||
572 573 574 575 576 577 578 579 580 581 582 583 584 585 | /*! * @class OFTXTDNSResourceRecord \ * OFDNSResourceRecord.h ObjFW/OFDNSResourceRecord.h * * @brief A class representing a TXT DNS resource record. */ @interface OFTXTDNSResourceRecord: OFDNSResourceRecord { OFData *_textData; } /*! * @brief The text of the resource record. | > | 583 584 585 586 587 588 589 590 591 592 593 594 595 596 597 | /*! * @class OFTXTDNSResourceRecord \ * OFDNSResourceRecord.h ObjFW/OFDNSResourceRecord.h * * @brief A class representing a TXT DNS resource record. */ OF_SUBCLASSING_RESTRICTED @interface OFTXTDNSResourceRecord: OFDNSResourceRecord { OFData *_textData; } /*! * @brief The text of the resource record. |
︙ | ︙ |
Modified src/OFData.h from [11c2950250] to [db711ac9ba].
︙ | ︙ | |||
39 40 41 42 43 44 45 46 47 48 49 50 51 52 | @interface OFData: OFObject <OFCopying, OFMutableCopying, OFComparing, OFSerialization, OFMessagePackRepresentation> { unsigned char *_items; size_t _count, _itemSize; bool _freeWhenDone; OFData *_parentData; } /*! * @brief The size of a single item in the OFData in bytes. */ @property (readonly, nonatomic) size_t itemSize; | > | 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 | @interface OFData: OFObject <OFCopying, OFMutableCopying, OFComparing, OFSerialization, OFMessagePackRepresentation> { unsigned char *_items; size_t _count, _itemSize; bool _freeWhenDone; OFData *_parentData; OF_RESERVE_IVARS(4) } /*! * @brief The size of a single item in the OFData in bytes. */ @property (readonly, nonatomic) size_t itemSize; |
︙ | ︙ |
Modified src/OFDate.h from [1c9dc17f4c] to [ef356199a7].
︙ | ︙ | |||
25 26 27 28 29 30 31 32 33 34 35 36 37 38 | @class OFConstantString; /*! * @class OFDate OFDate.h ObjFW/OFDate.h * * @brief A class for storing, accessing and comparing dates. */ @interface OFDate: OFObject <OFCopying, OFComparing, OFSerialization, OFMessagePackRepresentation> { of_time_interval_t _seconds; } #ifdef OF_HAVE_CLASS_PROPERTIES | > | 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 | @class OFConstantString; /*! * @class OFDate OFDate.h ObjFW/OFDate.h * * @brief A class for storing, accessing and comparing dates. */ OF_SUBCLASSING_RESTRICTED @interface OFDate: OFObject <OFCopying, OFComparing, OFSerialization, OFMessagePackRepresentation> { of_time_interval_t _seconds; } #ifdef OF_HAVE_CLASS_PROPERTIES |
︙ | ︙ |
Modified src/OFDictionary.h from [2fc9d82347] to [0bdd64401a].
︙ | ︙ | |||
58 59 60 61 62 63 64 65 66 67 68 69 70 71 | @interface OFDictionary OF_GENERIC(KeyType, ObjectType): OFObject <OFCopying, OFMutableCopying, OFCollection, OFSerialization, OFJSONRepresentation, OFMessagePackRepresentation> #if !defined(OF_HAVE_GENERICS) && !defined(DOXYGEN) # define KeyType id # define ObjectType id #endif /*! * @brief An array of all keys. */ @property (readonly, nonatomic) OFArray OF_GENERIC(KeyType) *allKeys; /*! * @brief An array of all objects. | > > > > | 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 | @interface OFDictionary OF_GENERIC(KeyType, ObjectType): OFObject <OFCopying, OFMutableCopying, OFCollection, OFSerialization, OFJSONRepresentation, OFMessagePackRepresentation> #if !defined(OF_HAVE_GENERICS) && !defined(DOXYGEN) # define KeyType id # define ObjectType id #endif { OF_RESERVE_IVARS(4) } /*! * @brief An array of all keys. */ @property (readonly, nonatomic) OFArray OF_GENERIC(KeyType) *allKeys; /*! * @brief An array of all objects. |
︙ | ︙ |
Modified src/OFDimensionValue.h from [506e11e7af] to [4f99589b0d].
︙ | ︙ | |||
15 16 17 18 19 20 21 22 23 24 25 26 27 28 | * file. */ #import "OFValue.h" OF_ASSUME_NONNULL_BEGIN @interface OFDimensionValue: OFValue { of_dimension_t _dimension; } @end OF_ASSUME_NONNULL_END | > | 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 | * file. */ #import "OFValue.h" OF_ASSUME_NONNULL_BEGIN OF_SUBCLASSING_RESTRICTED @interface OFDimensionValue: OFValue { of_dimension_t _dimension; } @end OF_ASSUME_NONNULL_END |
Modified src/OFEnumerator.h from [5d33d7fcc0] to [1264743def].
︙ | ︙ | |||
92 93 94 95 96 97 98 99 100 101 102 103 104 105 | * * @brief A class which provides methods to enumerate through collections. */ @interface OFEnumerator OF_GENERIC(ObjectType): OFObject <OFFastEnumeration> #if !defined(OF_HAVE_GENERICS) && !defined(DOXYGEN) # define ObjectType id #endif /*! * @brief Returns the next object or `nil` if there is none left. * * @return The next object or `nil` if there is none left */ - (nullable ObjectType)nextObject; | > > > > | 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 | * * @brief A class which provides methods to enumerate through collections. */ @interface OFEnumerator OF_GENERIC(ObjectType): OFObject <OFFastEnumeration> #if !defined(OF_HAVE_GENERICS) && !defined(DOXYGEN) # define ObjectType id #endif { OF_RESERVE_IVARS(4) } /*! * @brief Returns the next object or `nil` if there is none left. * * @return The next object or `nil` if there is none left */ - (nullable ObjectType)nextObject; |
︙ | ︙ |
Modified src/OFEpollKernelEventObserver.h from [a52cc0d821] to [82f0a9bae6].
︙ | ︙ | |||
17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 | #import "OFKernelEventObserver.h" OF_ASSUME_NONNULL_BEGIN @class OFMapTable; @interface OFEpollKernelEventObserver: OFKernelEventObserver { int _epfd; OFMapTable *_FDToEvents; } @end OF_ASSUME_NONNULL_END | > | 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 | #import "OFKernelEventObserver.h" OF_ASSUME_NONNULL_BEGIN @class OFMapTable; OF_SUBCLASSING_RESTRICTED @interface OFEpollKernelEventObserver: OFKernelEventObserver { int _epfd; OFMapTable *_FDToEvents; } @end OF_ASSUME_NONNULL_END |
Modified src/OFFile.h from [5cdb803aa0] to [7b7e5b1049].
︙ | ︙ | |||
32 33 34 35 36 37 38 39 40 41 42 43 44 45 | @class OFURL; /*! * @class OFFile OFFile.h ObjFW/OFFile.h * * @brief A class which provides methods to read and write files. */ @interface OFFile: OFSeekableStream #ifdef OF_FILE_HANDLE_IS_FD <OFReadyForReadingObserving, OFReadyForWritingObserving> #endif { of_file_handle_t _handle; bool _atEndOfStream; | > | 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 | @class OFURL; /*! * @class OFFile OFFile.h ObjFW/OFFile.h * * @brief A class which provides methods to read and write files. */ OF_SUBCLASSING_RESTRICTED @interface OFFile: OFSeekableStream #ifdef OF_FILE_HANDLE_IS_FD <OFReadyForReadingObserving, OFReadyForWritingObserving> #endif { of_file_handle_t _handle; bool _atEndOfStream; |
︙ | ︙ |
Modified src/OFFileManager.h from [daabb28b95] to [105f32a771].
︙ | ︙ | |||
238 239 240 241 242 243 244 245 246 247 248 249 250 251 | /*! * @class OFFileManager OFFileManager.h ObjFW/OFFileManager.h * * @brief A class which provides management for files, e.g. reading contents of * directories, deleting files, renaming files, etc. */ @interface OFFileManager: OFObject #ifdef OF_HAVE_CLASS_PROPERTIES @property (class, readonly, nonatomic) OFFileManager *defaultManager; #endif #ifdef OF_HAVE_FILES /*! | > > > | 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 | /*! * @class OFFileManager OFFileManager.h ObjFW/OFFileManager.h * * @brief A class which provides management for files, e.g. reading contents of * directories, deleting files, renaming files, etc. */ #ifndef OF_FILE_MANAGER_M OF_SUBCLASSING_RESTRICTED #endif @interface OFFileManager: OFObject #ifdef OF_HAVE_CLASS_PROPERTIES @property (class, readonly, nonatomic) OFFileManager *defaultManager; #endif #ifdef OF_HAVE_FILES /*! |
︙ | ︙ |
Modified src/OFFileManager.m from [5c4544e132] to [1b86de4488].
︙ | ︙ | |||
12 13 14 15 16 17 18 19 20 21 22 23 24 25 | * Alternatively, it may be distributed under the terms of the GNU General * Public License, either version 2 or 3, which can be found in the file * LICENSE.GPLv2 or LICENSE.GPLv3 respectively included in the packaging of this * file. */ #include "config.h" #include <errno.h> #include <limits.h> #include "unistd_wrapper.h" #import "platform.h" | > > | 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 | * Alternatively, it may be distributed under the terms of the GNU General * Public License, either version 2 or 3, which can be found in the file * LICENSE.GPLv2 or LICENSE.GPLv3 respectively included in the packaging of this * file. */ #include "config.h" #define OF_FILE_MANAGER_M #include <errno.h> #include <limits.h> #include "unistd_wrapper.h" #import "platform.h" |
︙ | ︙ |
Modified src/OFFileURLHandler.h from [4c8d0c729e] to [fd0c855548].
︙ | ︙ | |||
15 16 17 18 19 20 21 22 23 24 25 26 | * file. */ #import "OFURLHandler.h" OF_ASSUME_NONNULL_BEGIN @interface OFFileURLHandler: OFURLHandler + (bool)of_directoryExistsAtPath: (OFString *)path; @end OF_ASSUME_NONNULL_END | > | 15 16 17 18 19 20 21 22 23 24 25 26 27 | * file. */ #import "OFURLHandler.h" OF_ASSUME_NONNULL_BEGIN OF_SUBCLASSING_RESTRICTED @interface OFFileURLHandler: OFURLHandler + (bool)of_directoryExistsAtPath: (OFString *)path; @end OF_ASSUME_NONNULL_END |
Modified src/OFGZIPStream.h from [61111b955d] to [3973ccf74c].
︙ | ︙ | |||
24 25 26 27 28 29 30 31 32 33 34 35 36 37 | /*! * @class OFGZIPStream OFGZIPStream.h ObjFW/OFGZIPStream.h * * @brief A class that handles GZIP compression and decompression transparently * for an underlying stream. */ @interface OFGZIPStream: OFStream { OFStream *_stream; OFInflateStream *_Nullable _inflateStream; enum of_gzip_stream_state { OF_GZIP_STREAM_ID1, OF_GZIP_STREAM_ID2, | > | 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 | /*! * @class OFGZIPStream OFGZIPStream.h ObjFW/OFGZIPStream.h * * @brief A class that handles GZIP compression and decompression transparently * for an underlying stream. */ OF_SUBCLASSING_RESTRICTED @interface OFGZIPStream: OFStream { OFStream *_stream; OFInflateStream *_Nullable _inflateStream; enum of_gzip_stream_state { OF_GZIP_STREAM_ID1, OF_GZIP_STREAM_ID2, |
︙ | ︙ |
Modified src/OFHMAC.h from [f906bf7f17] to [c85420d05a].
︙ | ︙ | |||
21 22 23 24 25 26 27 28 29 30 31 32 33 34 | OF_ASSUME_NONNULL_BEGIN /*! * @class OFHMAC OFHMAC.h ObjFW/OFHMAC.h * * @brief A class which provides methods to calculate an HMAC. */ @interface OFHMAC: OFObject { Class <OFCryptoHash> _hashClass; id <OFCryptoHash> _Nullable _outerHash, _innerHash; id <OFCryptoHash> _Nullable _outerHashCopy, _innerHashCopy; bool _calculated; } | > | 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 | OF_ASSUME_NONNULL_BEGIN /*! * @class OFHMAC OFHMAC.h ObjFW/OFHMAC.h * * @brief A class which provides methods to calculate an HMAC. */ OF_SUBCLASSING_RESTRICTED @interface OFHMAC: OFObject { Class <OFCryptoHash> _hashClass; id <OFCryptoHash> _Nullable _outerHash, _innerHash; id <OFCryptoHash> _Nullable _outerHashCopy, _innerHashCopy; bool _calculated; } |
︙ | ︙ |
Modified src/OFHTTPClient.h from [ec1691a772] to [e516a827e2].
︙ | ︙ | |||
136 137 138 139 140 141 142 143 144 145 146 147 148 149 | @end /*! * @class OFHTTPClient OFHTTPClient.h ObjFW/OFHTTPClient.h * * @brief A class for performing HTTP requests. */ @interface OFHTTPClient: OFObject { #ifdef OF_HTTPCLIENT_M @public #endif OFObject <OFHTTPClientDelegate> *_Nullable _delegate; bool _insecureRedirectsAllowed, _inProgress; | > | 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 | @end /*! * @class OFHTTPClient OFHTTPClient.h ObjFW/OFHTTPClient.h * * @brief A class for performing HTTP requests. */ OF_SUBCLASSING_RESTRICTED @interface OFHTTPClient: OFObject { #ifdef OF_HTTPCLIENT_M @public #endif OFObject <OFHTTPClientDelegate> *_Nullable _delegate; bool _insecureRedirectsAllowed, _inProgress; |
︙ | ︙ |
Modified src/OFHTTPCookie.h from [de4eb9913d] to [e642b0f59d].
︙ | ︙ | |||
33 34 35 36 37 38 39 40 41 42 43 44 45 46 | */ @interface OFHTTPCookie: OFObject <OFCopying> { OFString *_name, *_value, *_domain, *_path; OFDate *_Nullable _expires; bool _secure, _HTTPOnly; OFMutableArray OF_GENERIC(OFString *) *_extensions; } /*! * @brief The name of the cookie. */ @property (copy, nonatomic) OFString *name; | > | 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 | */ @interface OFHTTPCookie: OFObject <OFCopying> { OFString *_name, *_value, *_domain, *_path; OFDate *_Nullable _expires; bool _secure, _HTTPOnly; OFMutableArray OF_GENERIC(OFString *) *_extensions; OF_RESERVE_IVARS(4) } /*! * @brief The name of the cookie. */ @property (copy, nonatomic) OFString *name; |
︙ | ︙ |
Modified src/OFHTTPCookieManager.h from [c6413b38bf] to [8c7af02c16].
︙ | ︙ | |||
25 26 27 28 29 30 31 32 33 34 35 36 37 38 | @class OFURL; /*! * @class OFHTTPCookieManager OFHTTPCookieManager.h ObjFW/OFHTTPCookieManager.h * * @brief A class for managing cookies for multiple domains. */ @interface OFHTTPCookieManager: OFObject { OFMutableArray OF_GENERIC(OFHTTPCookie *) *_cookies; } /*! * @brief All cookies known to the cookie manager. | > | 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 | @class OFURL; /*! * @class OFHTTPCookieManager OFHTTPCookieManager.h ObjFW/OFHTTPCookieManager.h * * @brief A class for managing cookies for multiple domains. */ OF_SUBCLASSING_RESTRICTED @interface OFHTTPCookieManager: OFObject { OFMutableArray OF_GENERIC(OFHTTPCookie *) *_cookies; } /*! * @brief All cookies known to the cookie manager. |
︙ | ︙ |
Modified src/OFHTTPRequest.h from [b110c8f2e2] to [9466bbaa67].
︙ | ︙ | |||
72 73 74 75 76 77 78 79 80 81 82 83 84 85 | @interface OFHTTPRequest: OFObject <OFCopying> { OFURL *_URL; of_http_request_method_t _method; of_http_request_protocol_version_t _protocolVersion; OFDictionary OF_GENERIC(OFString *, OFString *) *_Nullable _headers; of_socket_address_t _remoteAddress; } /*! * @brief The URL of the HTTP request. */ @property (copy, nonatomic) OFURL *URL; | > | 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 | @interface OFHTTPRequest: OFObject <OFCopying> { OFURL *_URL; of_http_request_method_t _method; of_http_request_protocol_version_t _protocolVersion; OFDictionary OF_GENERIC(OFString *, OFString *) *_Nullable _headers; of_socket_address_t _remoteAddress; OF_RESERVE_IVARS(4) } /*! * @brief The URL of the HTTP request. */ @property (copy, nonatomic) OFURL *URL; |
︙ | ︙ |
Modified src/OFHTTPResponse.h from [14b68dfcaa] to [4def471fb7].
︙ | ︙ | |||
29 30 31 32 33 34 35 36 37 38 39 40 41 42 | * @brief A class for representing an HTTP request reply as a stream. */ @interface OFHTTPResponse: OFStream { of_http_request_protocol_version_t _protocolVersion; short _statusCode; OFDictionary OF_GENERIC(OFString *, OFString *) *_headers; } /*! * @brief The protocol version of the HTTP request reply. */ @property (nonatomic) of_http_request_protocol_version_t protocolVersion; | > | 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 | * @brief A class for representing an HTTP request reply as a stream. */ @interface OFHTTPResponse: OFStream { of_http_request_protocol_version_t _protocolVersion; short _statusCode; OFDictionary OF_GENERIC(OFString *, OFString *) *_headers; OF_RESERVE_IVARS(4) } /*! * @brief The protocol version of the HTTP request reply. */ @property (nonatomic) of_http_request_protocol_version_t protocolVersion; |
︙ | ︙ |
Modified src/OFHTTPServer.h from [3394497349] to [cd787cb48e].
︙ | ︙ | |||
86 87 88 89 90 91 92 93 94 95 96 97 98 99 | @end /*! * @class OFHTTPServer OFHTTPServer.h ObjFW/OFHTTPServer.h * * @brief A class for creating a simple HTTP server inside of applications. */ @interface OFHTTPServer: OFObject { OFString *_Nullable _host; uint16_t _port; bool _usesTLS; OFString *_Nullable _certificateFile, *_Nullable _privateKeyFile; const char *_Nullable _privateKeyPassphrase; | > | 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 | @end /*! * @class OFHTTPServer OFHTTPServer.h ObjFW/OFHTTPServer.h * * @brief A class for creating a simple HTTP server inside of applications. */ OF_SUBCLASSING_RESTRICTED @interface OFHTTPServer: OFObject { OFString *_Nullable _host; uint16_t _port; bool _usesTLS; OFString *_Nullable _certificateFile, *_Nullable _privateKeyFile; const char *_Nullable _privateKeyPassphrase; |
︙ | ︙ |
Modified src/OFHTTPURLHandler.h from [9220399ab4] to [8c0000bba5].
︙ | ︙ | |||
15 16 17 18 19 20 21 22 23 24 25 | * file. */ #import "OFURLHandler.h" OF_ASSUME_NONNULL_BEGIN @interface OFHTTPURLHandler: OFURLHandler @end OF_ASSUME_NONNULL_END | > | 15 16 17 18 19 20 21 22 23 24 25 26 | * file. */ #import "OFURLHandler.h" OF_ASSUME_NONNULL_BEGIN OF_SUBCLASSING_RESTRICTED @interface OFHTTPURLHandler: OFURLHandler @end OF_ASSUME_NONNULL_END |
Modified src/OFINICategory.h from [a52c1059f2] to [cfca4456a9].
︙ | ︙ | |||
24 25 26 27 28 29 30 31 32 33 34 35 36 37 | @class OFString; /*! * @class OFINICategory OFINICategory.h ObjFW/OFINICategory.h * * @brief A class for representing a category of an INI file. */ @interface OFINICategory: OFObject { OFString *_name; OFMutableArray *_lines; } /*! | > | 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 | @class OFString; /*! * @class OFINICategory OFINICategory.h ObjFW/OFINICategory.h * * @brief A class for representing a category of an INI file. */ OF_SUBCLASSING_RESTRICTED @interface OFINICategory: OFObject { OFString *_name; OFMutableArray *_lines; } /*! |
︙ | ︙ |
Modified src/OFINIFile.h from [772b56ea19] to [71d6c12d86].
︙ | ︙ | |||
24 25 26 27 28 29 30 31 32 33 34 35 36 37 | @class OFMutableArray OF_GENERIC(ObjectType); /*! * @class OFINIFile OFINIFile.h ObjFW/OFINIFile.h * * @brief A class for reading, creating and modifying INI files. */ @interface OFINIFile: OFObject { OFMutableArray OF_GENERIC(OFINICategory *) *_categories; } /*! * @brief Creates a new OFINIFile with the contents of the specified file. | > | 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 | @class OFMutableArray OF_GENERIC(ObjectType); /*! * @class OFINIFile OFINIFile.h ObjFW/OFINIFile.h * * @brief A class for reading, creating and modifying INI files. */ OF_SUBCLASSING_RESTRICTED @interface OFINIFile: OFObject { OFMutableArray OF_GENERIC(OFINICategory *) *_categories; } /*! * @brief Creates a new OFINIFile with the contents of the specified file. |
︙ | ︙ |
Modified src/OFINIFileSettings.h from [0f40811c1f] to [bae8a4f75c].
︙ | ︙ | |||
18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 | #import "OFSettings.h" OF_ASSUME_NONNULL_BEGIN @class OFString; @class OFINIFile; @interface OFINIFileSettings: OFSettings { OFString *_filePath; OFINIFile *_INIFile; } @end OF_ASSUME_NONNULL_END | > | 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 | #import "OFSettings.h" OF_ASSUME_NONNULL_BEGIN @class OFString; @class OFINIFile; OF_SUBCLASSING_RESTRICTED @interface OFINIFileSettings: OFSettings { OFString *_filePath; OFINIFile *_INIFile; } @end OF_ASSUME_NONNULL_END |
Modified src/OFInflate64Stream.h from [7e95b67f65] to [7497e2c385].
︙ | ︙ | |||
27 28 29 30 31 32 33 34 35 36 37 38 39 40 | * * @note This class only conforms to OFReadyForReadingObserving if the * underlying stream does so, too. * * @brief A class that handles Deflate decompression transparently for an * underlying stream. */ @interface OFInflate64Stream: OFStream <OFReadyForReadingObserving> { #ifdef OF_INFLATE64_STREAM_M @public #endif OFStream *_stream; unsigned char _buffer[OF_INFLATE64_STREAM_BUFFER_SIZE]; | > | 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 | * * @note This class only conforms to OFReadyForReadingObserving if the * underlying stream does so, too. * * @brief A class that handles Deflate decompression transparently for an * underlying stream. */ OF_SUBCLASSING_RESTRICTED @interface OFInflate64Stream: OFStream <OFReadyForReadingObserving> { #ifdef OF_INFLATE64_STREAM_M @public #endif OFStream *_stream; unsigned char _buffer[OF_INFLATE64_STREAM_BUFFER_SIZE]; |
︙ | ︙ |
Modified src/OFInflateStream.h from [ba3144156c] to [a451ce0366].
︙ | ︙ | |||
27 28 29 30 31 32 33 34 35 36 37 38 39 40 | * * @note This class only conforms to OFReadyForReadingObserving if the * underlying stream does so, too. * * @brief A class that handles Deflate decompression transparently for an * underlying stream. */ @interface OFInflateStream: OFStream <OFReadyForReadingObserving> { #ifdef OF_INFLATE_STREAM_M @public #endif OFStream *_stream; unsigned char _buffer[OF_INFLATE_STREAM_BUFFER_SIZE]; | > | 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 | * * @note This class only conforms to OFReadyForReadingObserving if the * underlying stream does so, too. * * @brief A class that handles Deflate decompression transparently for an * underlying stream. */ OF_SUBCLASSING_RESTRICTED @interface OFInflateStream: OFStream <OFReadyForReadingObserving> { #ifdef OF_INFLATE_STREAM_M @public #endif OFStream *_stream; unsigned char _buffer[OF_INFLATE_STREAM_BUFFER_SIZE]; |
︙ | ︙ |
Modified src/OFIntrospection.h from [29246596c0] to [f4fdf94694].
︙ | ︙ | |||
42 43 44 45 46 47 48 49 50 51 52 53 54 55 | * @brief A class for describing a method. */ @interface OFMethod: OFObject { SEL _selector; OFString *_name; const char *_typeEncoding; } /*! * @brief The selector of the method. */ @property (readonly, nonatomic) SEL selector; | > | 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 | * @brief A class for describing a method. */ @interface OFMethod: OFObject { SEL _selector; OFString *_name; const char *_typeEncoding; OF_RESERVE_IVARS(4) } /*! * @brief The selector of the method. */ @property (readonly, nonatomic) SEL selector; |
︙ | ︙ | |||
72 73 74 75 76 77 78 79 80 81 82 83 84 85 | * @brief A class for describing a property. */ @interface OFProperty: OFObject { OFString *_name; unsigned int _attributes; OFString *_Nullable _getter, *_Nullable _setter, *_Nullable _iVar; } /*! * @brief The name of the property. */ @property (readonly, nonatomic) OFString *name; | > | 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 | * @brief A class for describing a property. */ @interface OFProperty: OFObject { OFString *_name; unsigned int _attributes; OFString *_Nullable _getter, *_Nullable _setter, *_Nullable _iVar; OF_RESERVE_IVARS(4) } /*! * @brief The name of the property. */ @property (readonly, nonatomic) OFString *name; |
︙ | ︙ | |||
126 127 128 129 130 131 132 133 134 135 136 137 138 139 | * @brief A class for describing an instance variable. */ @interface OFInstanceVariable: OFObject { OFString *_name; const char *_typeEncoding; ptrdiff_t _offset; } /*! * @brief The name of the instance variable. */ @property (readonly, nonatomic) OFString *name; | > | 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 | * @brief A class for describing an instance variable. */ @interface OFInstanceVariable: OFObject { OFString *_name; const char *_typeEncoding; ptrdiff_t _offset; OF_RESERVE_IVARS(4) } /*! * @brief The name of the instance variable. */ @property (readonly, nonatomic) OFString *name; |
︙ | ︙ | |||
151 152 153 154 155 156 157 158 159 160 161 162 163 164 | @end /*! * @class OFIntrospection OFIntrospection.h ObjFW/OFIntrospection.h * * @brief A class for introspecting classes. */ @interface OFIntrospection: OFObject { OFMutableArray OF_GENERIC(OFMethod *) *_classMethods; OFMutableArray OF_GENERIC(OFMethod *) *_instanceMethods; OFMutableArray OF_GENERIC(OFProperty *) *_properties; OFMutableArray OF_GENERIC(OFInstanceVariable *) *_instanceVariables; } | > | 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 | @end /*! * @class OFIntrospection OFIntrospection.h ObjFW/OFIntrospection.h * * @brief A class for introspecting classes. */ OF_SUBCLASSING_RESTRICTED @interface OFIntrospection: OFObject { OFMutableArray OF_GENERIC(OFMethod *) *_classMethods; OFMutableArray OF_GENERIC(OFMethod *) *_instanceMethods; OFMutableArray OF_GENERIC(OFProperty *) *_properties; OFMutableArray OF_GENERIC(OFInstanceVariable *) *_instanceVariables; } |
︙ | ︙ |
Modified src/OFInvertedCharacterSet.h from [e78ee993d6] to [1f748d556a].
︙ | ︙ | |||
15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 | * file. */ #import "OFCharacterSet.h" OF_ASSUME_NONNULL_BEGIN @interface OFInvertedCharacterSet: OFCharacterSet { OFCharacterSet *_characterSet; bool (*_characterIsMember)(id, SEL, of_unichar_t); } - (instancetype)of_initWithCharacterSet: (OFCharacterSet *)characterSet OF_METHOD_FAMILY(init); @end OF_ASSUME_NONNULL_END | > | 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 | * file. */ #import "OFCharacterSet.h" OF_ASSUME_NONNULL_BEGIN OF_SUBCLASSING_RESTRICTED @interface OFInvertedCharacterSet: OFCharacterSet { OFCharacterSet *_characterSet; bool (*_characterIsMember)(id, SEL, of_unichar_t); } - (instancetype)of_initWithCharacterSet: (OFCharacterSet *)characterSet OF_METHOD_FAMILY(init); @end OF_ASSUME_NONNULL_END |
Modified src/OFInvocation.h from [24df5b6a45] to [a768f545d5].
︙ | ︙ | |||
29 30 31 32 33 34 35 36 37 38 39 40 41 42 | * @brief A class for storing and accessing invocations, and invoking them. */ @interface OFInvocation: OFObject { OFMethodSignature *_methodSignature; OFMutableArray OF_GENERIC(OFMutableData *) *_arguments; OFMutableData *_returnValue; } /*! * @brief The method signature for the invocation. */ @property (readonly, nonatomic) OFMethodSignature *methodSignature; | > | 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 | * @brief A class for storing and accessing invocations, and invoking them. */ @interface OFInvocation: OFObject { OFMethodSignature *_methodSignature; OFMutableArray OF_GENERIC(OFMutableData *) *_arguments; OFMutableData *_returnValue; OF_RESERVE_IVARS(4) } /*! * @brief The method signature for the invocation. */ @property (readonly, nonatomic) OFMethodSignature *methodSignature; |
︙ | ︙ |
Modified src/OFKernelEventObserver.h from [97255f4a8b] to [b2d4e300e7].
︙ | ︙ | |||
137 138 139 140 141 142 143 144 145 146 147 148 149 150 | OFMutex *_mutex; #endif OFMutableData *_queueActions; OFMutableArray *_queueObjects; #ifdef OF_AMIGAOS ULONG _execSignalMask; #endif } /*! * @brief The delegate for the OFKernelEventObserver. */ @property OF_NULLABLE_PROPERTY (assign, nonatomic) id <OFKernelEventObserverDelegate> delegate; | > | 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 | OFMutex *_mutex; #endif OFMutableData *_queueActions; OFMutableArray *_queueObjects; #ifdef OF_AMIGAOS ULONG _execSignalMask; #endif OF_RESERVE_IVARS(4) } /*! * @brief The delegate for the OFKernelEventObserver. */ @property OF_NULLABLE_PROPERTY (assign, nonatomic) id <OFKernelEventObserverDelegate> delegate; |
︙ | ︙ |
Modified src/OFKqueueKernelEventObserver.h from [93173a129b] to [04d72570f9].
︙ | ︙ | |||
17 18 19 20 21 22 23 24 25 26 27 28 29 30 | #import "OFKernelEventObserver.h" OF_ASSUME_NONNULL_BEGIN @class OFMutableArray OF_GENERIC(ObjectType); @interface OFKqueueKernelEventObserver: OFKernelEventObserver { int _kernelQueue; } @end OF_ASSUME_NONNULL_END | > | 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 | #import "OFKernelEventObserver.h" OF_ASSUME_NONNULL_BEGIN @class OFMutableArray OF_GENERIC(ObjectType); OF_SUBCLASSING_RESTRICTED @interface OFKqueueKernelEventObserver: OFKernelEventObserver { int _kernelQueue; } @end OF_ASSUME_NONNULL_END |
Modified src/OFLHAArchive.h from [667a6061aa] to [98e95db909].
︙ | ︙ | |||
25 26 27 28 29 30 31 32 33 34 35 36 37 38 | @class OFStream; /*! * @class OFLHAArchive OFLHAArchive.h ObjFW/OFLHAArchive.h * * @brief A class for accessing and manipulating LHA files. */ @interface OFLHAArchive: OFObject { OFStream *_stream; enum { OF_LHA_ARCHIVE_MODE_READ, OF_LHA_ARCHIVE_MODE_WRITE, OF_LHA_ARCHIVE_MODE_APPEND | > | 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 | @class OFStream; /*! * @class OFLHAArchive OFLHAArchive.h ObjFW/OFLHAArchive.h * * @brief A class for accessing and manipulating LHA files. */ OF_SUBCLASSING_RESTRICTED @interface OFLHAArchive: OFObject { OFStream *_stream; enum { OF_LHA_ARCHIVE_MODE_READ, OF_LHA_ARCHIVE_MODE_WRITE, OF_LHA_ARCHIVE_MODE_APPEND |
︙ | ︙ |
Modified src/OFLHAArchiveEntry.h from [4b4440a6ad] to [a2fc14bd84].
︙ | ︙ | |||
43 44 45 46 47 48 49 50 51 52 53 54 55 56 | uint16_t _CRC16; uint8_t _operatingSystemIdentifier; OFString *_Nullable _fileComment; OFNumber *_Nullable _mode, *_Nullable _UID, *_Nullable _GID; OFString *_Nullable _owner, *_Nullable _group; OFDate *_Nullable _modificationDate; OFMutableArray OF_GENERIC(OFData *) *_extensions; } /*! * @brief The file name of the entry. */ @property (readonly, copy, nonatomic) OFString *fileName; | > | 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 | uint16_t _CRC16; uint8_t _operatingSystemIdentifier; OFString *_Nullable _fileComment; OFNumber *_Nullable _mode, *_Nullable _UID, *_Nullable _GID; OFString *_Nullable _owner, *_Nullable _group; OFDate *_Nullable _modificationDate; OFMutableArray OF_GENERIC(OFData *) *_extensions; OF_RESERVE_IVARS(4) } /*! * @brief The file name of the entry. */ @property (readonly, copy, nonatomic) OFString *fileName; |
︙ | ︙ |
Modified src/OFLHADecompressingStream.h from [1fd5de7afc] to [e5a15c8e0b].
︙ | ︙ | |||
17 18 19 20 21 22 23 24 25 26 27 28 29 30 | #import "OFStream.h" OF_ASSUME_NONNULL_BEGIN #define OF_LHA_DECOMPRESSING_STREAM_BUFFER_SIZE 4096 @interface OFLHADecompressingStream: OFStream { @public OFStream *_stream; uint8_t _distanceBits, _dictionaryBits; unsigned char _buffer[OF_LHA_DECOMPRESSING_STREAM_BUFFER_SIZE]; uint32_t _bytesConsumed; | > | 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 | #import "OFStream.h" OF_ASSUME_NONNULL_BEGIN #define OF_LHA_DECOMPRESSING_STREAM_BUFFER_SIZE 4096 OF_SUBCLASSING_RESTRICTED @interface OFLHADecompressingStream: OFStream { @public OFStream *_stream; uint8_t _distanceBits, _dictionaryBits; unsigned char _buffer[OF_LHA_DECOMPRESSING_STREAM_BUFFER_SIZE]; uint32_t _bytesConsumed; |
︙ | ︙ |
Modified src/OFList.h from [6b57b93ef4] to [c1be030244].
︙ | ︙ | |||
51 52 53 54 55 56 57 58 59 60 61 62 63 64 | # define ObjectType id #endif { of_list_object_t *_Nullable _firstListObject; of_list_object_t *_Nullable _lastListObject; size_t _count; unsigned long _mutations; } /*! * @brief The first list object of the list. */ @property OF_NULLABLE_PROPERTY (readonly, nonatomic) of_list_object_t *firstListObject; | > | 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 | # define ObjectType id #endif { of_list_object_t *_Nullable _firstListObject; of_list_object_t *_Nullable _lastListObject; size_t _count; unsigned long _mutations; OF_RESERVE_IVARS(4) } /*! * @brief The first list object of the list. */ @property OF_NULLABLE_PROPERTY (readonly, nonatomic) of_list_object_t *firstListObject; |
︙ | ︙ |
Modified src/OFLocale.h from [42395bf4fa] to [fac49fcae1].
︙ | ︙ | |||
39 40 41 42 43 44 45 46 47 48 49 50 51 52 | @class OFDictionary OF_GENERIC(KeyType, ObjectType); /*! * @class OFLocale OFLocale.h ObjFW/OFLocale.h * * @brief A class for querying the locale and retrieving localized strings. */ @interface OFLocale: OFObject { OFString *_Nullable _language, *_Nullable _territory; of_string_encoding_t _encoding; OFString *_decimalPoint; OFMutableArray OF_GENERIC(OFDictionary OF_GENERIC(OFString *, id) *) *_localizedStrings; | > | 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 | @class OFDictionary OF_GENERIC(KeyType, ObjectType); /*! * @class OFLocale OFLocale.h ObjFW/OFLocale.h * * @brief A class for querying the locale and retrieving localized strings. */ OF_SUBCLASSING_RESTRICTED @interface OFLocale: OFObject { OFString *_Nullable _language, *_Nullable _territory; of_string_encoding_t _encoding; OFString *_decimalPoint; OFMutableArray OF_GENERIC(OFDictionary OF_GENERIC(OFString *, id) *) *_localizedStrings; |
︙ | ︙ |
Modified src/OFMD5Hash.h from [2507db3e19] to [7bc2b1da3f].
︙ | ︙ | |||
22 23 24 25 26 27 28 29 30 31 32 33 34 35 | @class OFSecureData; /*! * @class OFMD5Hash OFMD5Hash.h ObjFW/OFMD5Hash.h * * @brief A class which provides methods to create an MD5 hash. */ @interface OFMD5Hash: OFObject <OFCryptoHash> { OFSecureData *_iVarsData; struct of_md5_hash_ivars { uint32_t state[4]; uint64_t bits; union of_md5_hash_buffer { | > | 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 | @class OFSecureData; /*! * @class OFMD5Hash OFMD5Hash.h ObjFW/OFMD5Hash.h * * @brief A class which provides methods to create an MD5 hash. */ OF_SUBCLASSING_RESTRICTED @interface OFMD5Hash: OFObject <OFCryptoHash> { OFSecureData *_iVarsData; struct of_md5_hash_ivars { uint32_t state[4]; uint64_t bits; union of_md5_hash_buffer { |
︙ | ︙ |
Modified src/OFMapTable.h from [1f1f29d31e] to [b6dd6c63b6].
︙ | ︙ | |||
66 67 68 69 70 71 72 73 74 75 76 77 78 79 | /*! * @class OFMapTable OFMapTable.h ObjFW/OFMapTable.h * * @brief A class similar to OFDictionary, but providing more options how keys * and objects should be retained, released, compared and hashed. */ @interface OFMapTable: OFObject <OFCopying, OFFastEnumeration> { of_map_table_functions_t _keyFunctions, _objectFunctions; struct of_map_table_bucket *_Nonnull *_Nullable _buckets; uint32_t _count, _capacity; uint8_t _rotate; unsigned long _mutations; | > | 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 | /*! * @class OFMapTable OFMapTable.h ObjFW/OFMapTable.h * * @brief A class similar to OFDictionary, but providing more options how keys * and objects should be retained, released, compared and hashed. */ OF_SUBCLASSING_RESTRICTED @interface OFMapTable: OFObject <OFCopying, OFFastEnumeration> { of_map_table_functions_t _keyFunctions, _objectFunctions; struct of_map_table_bucket *_Nonnull *_Nullable _buckets; uint32_t _count, _capacity; uint8_t _rotate; unsigned long _mutations; |
︙ | ︙ |
Modified src/OFMapTableDictionary.h from [c6f471998e] to [e4b08c07d4].
︙ | ︙ | |||
18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 | #import "OFDictionary.h" OF_ASSUME_NONNULL_BEGIN @class OFMapTable; @class OFMapTableEnumerator; @interface OFMapTableDictionary: OFDictionary { OFMapTable *_mapTable; } - (instancetype)initWithCapacity: (size_t)capacity; @end OF_ASSUME_NONNULL_END | > | 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 | #import "OFDictionary.h" OF_ASSUME_NONNULL_BEGIN @class OFMapTable; @class OFMapTableEnumerator; OF_SUBCLASSING_RESTRICTED @interface OFMapTableDictionary: OFDictionary { OFMapTable *_mapTable; } - (instancetype)initWithCapacity: (size_t)capacity; @end OF_ASSUME_NONNULL_END |
Modified src/OFMapTableSet.h from [955e132003] to [87db5f22c7].
︙ | ︙ | |||
17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 | #import "OFSet.h" OF_ASSUME_NONNULL_BEGIN @class OFMapTable; @interface OFMapTableSet: OFSet { OFMapTable *_mapTable; } - (instancetype)initWithCapacity: (size_t)capacity; @end OF_ASSUME_NONNULL_END | > | 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 | #import "OFSet.h" OF_ASSUME_NONNULL_BEGIN @class OFMapTable; OF_SUBCLASSING_RESTRICTED @interface OFMapTableSet: OFSet { OFMapTable *_mapTable; } - (instancetype)initWithCapacity: (size_t)capacity; @end OF_ASSUME_NONNULL_END |
Modified src/OFMessagePackExtension.h from [947608cec6] to [bdf36008e7].
︙ | ︙ | |||
29 30 31 32 33 34 35 36 37 38 39 40 41 42 | * @brief A class for representing the MessagePack extension type. */ @interface OFMessagePackExtension: OFObject <OFMessagePackRepresentation, OFCopying> { int8_t _type; OFData *_data; } /*! * @brief The MessagePack extension type. */ @property (readonly, nonatomic) int8_t type; | > | 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 | * @brief A class for representing the MessagePack extension type. */ @interface OFMessagePackExtension: OFObject <OFMessagePackRepresentation, OFCopying> { int8_t _type; OFData *_data; OF_RESERVE_IVARS(4) } /*! * @brief The MessagePack extension type. */ @property (readonly, nonatomic) int8_t type; |
︙ | ︙ |
Modified src/OFMethodSignature.h from [35a14e0813] to [18c94d6350].
︙ | ︙ | |||
26 27 28 29 30 31 32 33 34 35 36 37 38 39 | * * @brief A class for parsing type encodings and accessing them. */ @interface OFMethodSignature: OFObject { char *_types; OFMutableData *_typesPointers, *_offsets; } /*! * @brief The number of arguments of the method. */ @property (readonly, nonatomic) size_t numberOfArguments; | > | 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 | * * @brief A class for parsing type encodings and accessing them. */ @interface OFMethodSignature: OFObject { char *_types; OFMutableData *_typesPointers, *_offsets; OF_RESERVE_IVARS(4) } /*! * @brief The number of arguments of the method. */ @property (readonly, nonatomic) size_t numberOfArguments; |
︙ | ︙ |
Modified src/OFMutableAdjacentArray.h from [ba9ae1bdf2] to [51288ab7a0].
︙ | ︙ | |||
17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 | #import "OFArray.h" OF_ASSUME_NONNULL_BEGIN @class OFMutableData; @interface OFMutableAdjacentArray: OFMutableArray { OFMutableData *_array; unsigned long _mutations; } @end OF_ASSUME_NONNULL_END | > | 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 | #import "OFArray.h" OF_ASSUME_NONNULL_BEGIN @class OFMutableData; OF_SUBCLASSING_RESTRICTED @interface OFMutableAdjacentArray: OFMutableArray { OFMutableData *_array; unsigned long _mutations; } @end OF_ASSUME_NONNULL_END |
Modified src/OFMutableArray.h from [97f317cd8c] to [34a09a316e].
︙ | ︙ | |||
42 43 44 45 46 47 48 49 50 51 52 53 54 55 | * @ref replaceObjectAtIndex:withObject:, @ref removeObjectAtIndex: as * well as all methods of @ref OFArray that need to be implemented. */ @interface OFMutableArray OF_GENERIC(ObjectType): OFArray OF_GENERIC(ObjectType) #if !defined(OF_HAVE_GENERICS) && !defined(DOXYGEN) # define ObjectType id #endif /*! * @brief Creates a new OFMutableArray with enough memory to hold the specified * number of objects. * * @param capacity The initial capacity for the OFMutableArray * @return A new autoreleased OFMutableArray */ | > > > > | 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 | * @ref replaceObjectAtIndex:withObject:, @ref removeObjectAtIndex: as * well as all methods of @ref OFArray that need to be implemented. */ @interface OFMutableArray OF_GENERIC(ObjectType): OFArray OF_GENERIC(ObjectType) #if !defined(OF_HAVE_GENERICS) && !defined(DOXYGEN) # define ObjectType id #endif { OF_RESERVE_IVARS(4) } /*! * @brief Creates a new OFMutableArray with enough memory to hold the specified * number of objects. * * @param capacity The initial capacity for the OFMutableArray * @return A new autoreleased OFMutableArray */ |
︙ | ︙ |
Modified src/OFMutableData.h from [5a53632ba0] to [ad7c91dbcd].
︙ | ︙ | |||
26 27 28 29 30 31 32 33 34 35 36 37 38 39 | * @class OFMutableData OFMutableData.h ObjFW/OFMutableData.h * * @brief A class for storing and manipulating arbitrary data in an array. */ @interface OFMutableData: OFData { size_t _capacity; } /*! * @brief All items of the OFMutableData as a C array. * * @warning The pointer is only valid until the OFMutableData is changed! * | > | 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 | * @class OFMutableData OFMutableData.h ObjFW/OFMutableData.h * * @brief A class for storing and manipulating arbitrary data in an array. */ @interface OFMutableData: OFData { size_t _capacity; OF_RESERVE_IVARS(4) } /*! * @brief All items of the OFMutableData as a C array. * * @warning The pointer is only valid until the OFMutableData is changed! * |
︙ | ︙ |
Modified src/OFMutableDictionary.h from [43070c71d1] to [e6550bad92].
︙ | ︙ | |||
43 44 45 46 47 48 49 50 51 52 53 54 55 56 | */ @interface OFMutableDictionary OF_GENERIC(KeyType, ObjectType): OFDictionary OF_GENERIC(KeyType, ObjectType) #if !defined(OF_HAVE_GENERICS) && !defined(DOXYGEN) # define KeyType id # define ObjectType id #endif /*! * @brief Creates a new OFMutableDictionary with enough memory to hold the * specified number of objects. * * @param capacity The initial capacity for the OFMutableDictionary * @return A new autoreleased OFMutableDictionary */ | > > > > | 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 | */ @interface OFMutableDictionary OF_GENERIC(KeyType, ObjectType): OFDictionary OF_GENERIC(KeyType, ObjectType) #if !defined(OF_HAVE_GENERICS) && !defined(DOXYGEN) # define KeyType id # define ObjectType id #endif { OF_RESERVE_IVARS(4) } /*! * @brief Creates a new OFMutableDictionary with enough memory to hold the * specified number of objects. * * @param capacity The initial capacity for the OFMutableDictionary * @return A new autoreleased OFMutableDictionary */ |
︙ | ︙ |
Modified src/OFMutableLHAArchiveEntry.h from [25550d850c] to [35040236c1].
︙ | ︙ | |||
22 23 24 25 26 27 28 29 30 31 32 33 34 35 | /*! * @class OFMutableLHAArchiveEntry \ * OFMutableLHAArchiveEntry.h ObjFW/OFMutableLHAArchiveEntry.h * * @brief A class which represents a mutable entry in an LHA archive. */ @interface OFMutableLHAArchiveEntry: OFLHAArchiveEntry /*! * @brief The file name of the entry. */ @property (readwrite, copy, nonatomic) OFString *fileName; /*! | > > > | 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 | /*! * @class OFMutableLHAArchiveEntry \ * OFMutableLHAArchiveEntry.h ObjFW/OFMutableLHAArchiveEntry.h * * @brief A class which represents a mutable entry in an LHA archive. */ @interface OFMutableLHAArchiveEntry: OFLHAArchiveEntry { OF_RESERVE_IVARS(4) } /*! * @brief The file name of the entry. */ @property (readwrite, copy, nonatomic) OFString *fileName; /*! |
︙ | ︙ |
Modified src/OFMutableMapTableDictionary.h from [dec5e52f1e] to [4d2fb14c64].
︙ | ︙ | |||
17 18 19 20 21 22 23 24 25 26 27 28 29 30 | #import "OFDictionary.h" OF_ASSUME_NONNULL_BEGIN @class OFMapTable; @interface OFMutableMapTableDictionary: OFMutableDictionary { OFMapTable *_mapTable; } @end OF_ASSUME_NONNULL_END | > | 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 | #import "OFDictionary.h" OF_ASSUME_NONNULL_BEGIN @class OFMapTable; OF_SUBCLASSING_RESTRICTED @interface OFMutableMapTableDictionary: OFMutableDictionary { OFMapTable *_mapTable; } @end OF_ASSUME_NONNULL_END |
Modified src/OFMutableMapTableSet.h from [59911fabdb] to [184041bad3].
︙ | ︙ | |||
17 18 19 20 21 22 23 24 25 26 27 28 29 30 | #import "OFMutableSet.h" OF_ASSUME_NONNULL_BEGIN @class OFMapTable; @interface OFMutableMapTableSet: OFMutableSet { OFMapTable *_mapTable; } @end OF_ASSUME_NONNULL_END | > | 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 | #import "OFMutableSet.h" OF_ASSUME_NONNULL_BEGIN @class OFMapTable; OF_SUBCLASSING_RESTRICTED @interface OFMutableMapTableSet: OFMutableSet { OFMapTable *_mapTable; } @end OF_ASSUME_NONNULL_END |
Modified src/OFMutablePair.h from [6bb98de460] to [243eba2a1e].
︙ | ︙ | |||
26 27 28 29 30 31 32 33 34 35 36 37 38 39 | */ @interface OFMutablePair OF_GENERIC(FirstType, SecondType): OFPair OF_GENERIC(FirstType, SecondType) #if !defined(OF_HAVE_GENERICS) && !defined(DOXYGEN) # define FirstType id # define SecondType id #endif /*! * @brief The first object of the pair. */ @property (readwrite, nonatomic, retain) FirstType firstObject; /*! * @brief The second object of the pair. | > > > > | 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 | */ @interface OFMutablePair OF_GENERIC(FirstType, SecondType): OFPair OF_GENERIC(FirstType, SecondType) #if !defined(OF_HAVE_GENERICS) && !defined(DOXYGEN) # define FirstType id # define SecondType id #endif { OF_RESERVE_IVARS(4) } /*! * @brief The first object of the pair. */ @property (readwrite, nonatomic, retain) FirstType firstObject; /*! * @brief The second object of the pair. |
︙ | ︙ |
Modified src/OFMutableSet.h from [9b1889a14f] to [ec355518ec].
︙ | ︙ | |||
27 28 29 30 31 32 33 34 35 36 37 38 39 40 | * @note Subclasses must implement @ref addObject:, @ref removeObject: as well * as all methods of @ref OFSet that need to be implemented. */ @interface OFMutableSet OF_GENERIC(ObjectType): OFSet OF_GENERIC(ObjectType) #if !defined(OF_HAVE_GENERICS) && !defined(DOXYGEN) # define ObjectType id #endif /*! * @brief Creates a new OFMutableSet with enough memory to hold the specified * number of objects. * * @param capacity The initial capacity for the OFMutableSet * @return A new autoreleased OFMutableSet */ | > > > > | 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 | * @note Subclasses must implement @ref addObject:, @ref removeObject: as well * as all methods of @ref OFSet that need to be implemented. */ @interface OFMutableSet OF_GENERIC(ObjectType): OFSet OF_GENERIC(ObjectType) #if !defined(OF_HAVE_GENERICS) && !defined(DOXYGEN) # define ObjectType id #endif { OF_RESERVE_IVARS(4) } /*! * @brief Creates a new OFMutableSet with enough memory to hold the specified * number of objects. * * @param capacity The initial capacity for the OFMutableSet * @return A new autoreleased OFMutableSet */ |
︙ | ︙ |
Modified src/OFMutableString.h from [b9fb78b26e] to [721df996ad].
︙ | ︙ | |||
21 22 23 24 25 26 27 28 29 30 31 32 33 34 | /*! * @class OFMutableString OFString.h ObjFW/OFString.h * * @brief A class for storing and modifying strings. */ @interface OFMutableString: OFString /*! * @brief Sets the character at the specified index. * * @param character The character to set * @param index The index where to set the character */ - (void)setCharacter: (of_unichar_t)character | > > > > | 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 | /*! * @class OFMutableString OFString.h ObjFW/OFString.h * * @brief A class for storing and modifying strings. */ @interface OFMutableString: OFString { OF_RESERVE_IVARS(4) } /*! * @brief Sets the character at the specified index. * * @param character The character to set * @param index The index where to set the character */ - (void)setCharacter: (of_unichar_t)character |
︙ | ︙ |
Modified src/OFMutableTarArchiveEntry.h from [301e1d8433] to [199bc4c41d].
︙ | ︙ | |||
22 23 24 25 26 27 28 29 30 31 32 33 34 35 | /*! * @class OFMutableTarArchiveEntry \ * OFMutableTarArchiveEntry.h ObjFW/OFMutableTarArchiveEntry.h * * @brief A class which represents a mutable entry of a tar archive. */ @interface OFMutableTarArchiveEntry: OFTarArchiveEntry /*! * @brief The file name of the entry. */ @property (readwrite, copy, nonatomic) OFString *fileName; /*! | > > > | 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 | /*! * @class OFMutableTarArchiveEntry \ * OFMutableTarArchiveEntry.h ObjFW/OFMutableTarArchiveEntry.h * * @brief A class which represents a mutable entry of a tar archive. */ @interface OFMutableTarArchiveEntry: OFTarArchiveEntry { OF_RESERVE_IVARS(4) } /*! * @brief The file name of the entry. */ @property (readwrite, copy, nonatomic) OFString *fileName; /*! |
︙ | ︙ |
Modified src/OFMutableTriple.h from [5621e7a8f4] to [524e2b7c05].
︙ | ︙ | |||
27 28 29 30 31 32 33 34 35 36 37 38 39 40 | @interface OFMutableTriple OF_GENERIC(FirstType, SecondType, ThirdType): OFTriple OF_GENERIC(FirstType, SecondType, ThirdType) #if !defined(OF_HAVE_GENERICS) && !defined(DOXYGEN) # define FirstType id # define SecondType id # define ThirdType id #endif /*! * @brief The first object of the triple. */ @property (readwrite, nonatomic, retain) FirstType firstObject; /*! * @brief The second object of the triple. | > > > > | 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 | @interface OFMutableTriple OF_GENERIC(FirstType, SecondType, ThirdType): OFTriple OF_GENERIC(FirstType, SecondType, ThirdType) #if !defined(OF_HAVE_GENERICS) && !defined(DOXYGEN) # define FirstType id # define SecondType id # define ThirdType id #endif { OF_RESERVE_IVARS(4) } /*! * @brief The first object of the triple. */ @property (readwrite, nonatomic, retain) FirstType firstObject; /*! * @brief The second object of the triple. |
︙ | ︙ |
Modified src/OFMutableURL.h from [eff60f9cda] to [3f13123c95].
︙ | ︙ | |||
21 22 23 24 25 26 27 28 29 30 31 32 33 34 | /*! * @class OFMutableURL OFMutableURL.h ObjFW/OFMutableURL.h * * @brief A class for parsing URLs and accessing parts of it. */ @interface OFMutableURL: OFURL /*! * @brief The scheme part of the URL. */ @property OF_NULLABLE_PROPERTY (readwrite, copy, nonatomic) OFString *scheme; /*! * @brief The scheme part of the URL in URL-encoded form. | > > > > | 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 | /*! * @class OFMutableURL OFMutableURL.h ObjFW/OFMutableURL.h * * @brief A class for parsing URLs and accessing parts of it. */ @interface OFMutableURL: OFURL { OF_RESERVE_IVARS(4) } /*! * @brief The scheme part of the URL. */ @property OF_NULLABLE_PROPERTY (readwrite, copy, nonatomic) OFString *scheme; /*! * @brief The scheme part of the URL in URL-encoded form. |
︙ | ︙ |
Modified src/OFMutableUTF8String.h from [039b0313df] to [bde0a714b5].
︙ | ︙ | |||
16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 | */ #import "OFMutableString.h" #import "OFUTF8String.h" OF_ASSUME_NONNULL_BEGIN @interface OFMutableUTF8String: OFMutableString { @public struct of_string_utf8_ivars *restrict _s; struct of_string_utf8_ivars _storage; } @end OF_ASSUME_NONNULL_END | > | 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 | */ #import "OFMutableString.h" #import "OFUTF8String.h" OF_ASSUME_NONNULL_BEGIN OF_SUBCLASSING_RESTRICTED @interface OFMutableUTF8String: OFMutableString { @public struct of_string_utf8_ivars *restrict _s; struct of_string_utf8_ivars _storage; } @end OF_ASSUME_NONNULL_END |
Modified src/OFMutableZIPArchiveEntry.h from [a5c9bd1076] to [860ca60c8f].
︙ | ︙ | |||
23 24 25 26 27 28 29 30 31 32 33 34 35 36 | * @class OFMutableZIPArchiveEntry \ * OFMutableZIPArchiveEntry.h ObjFW/OFMutableZIPArchiveEntry.h * * @brief A class which represents a mutable entry in the central directory of * a ZIP archive. */ @interface OFMutableZIPArchiveEntry: OFZIPArchiveEntry /*! * @brief The file name of the entry. */ @property (readwrite, copy, nonatomic) OFString *fileName; /*! | > > > | 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 | * @class OFMutableZIPArchiveEntry \ * OFMutableZIPArchiveEntry.h ObjFW/OFMutableZIPArchiveEntry.h * * @brief A class which represents a mutable entry in the central directory of * a ZIP archive. */ @interface OFMutableZIPArchiveEntry: OFZIPArchiveEntry { OF_RESERVE_IVARS(4) } /*! * @brief The file name of the entry. */ @property (readwrite, copy, nonatomic) OFString *fileName; /*! |
︙ | ︙ |
Modified src/OFMutex.h from [4b8e64a2be] to [4ff73c2003].
︙ | ︙ | |||
28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 | * @brief A class for creating mutual exclusions. */ @interface OFMutex: OFObject <OFLocking> { of_mutex_t _mutex; bool _initialized; OFString *_Nullable _name; } /*! * @brief Creates a new mutex. * * @return A new autoreleased mutex. */ + (instancetype)mutex; @end OF_ASSUME_NONNULL_END | > | 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 | * @brief A class for creating mutual exclusions. */ @interface OFMutex: OFObject <OFLocking> { of_mutex_t _mutex; bool _initialized; OFString *_Nullable _name; OF_RESERVE_IVARS(4) } /*! * @brief Creates a new mutex. * * @return A new autoreleased mutex. */ + (instancetype)mutex; @end OF_ASSUME_NONNULL_END |
Modified src/OFNonretainedObjectValue.h from [c355b53946] to [36f80cbb4e].
︙ | ︙ | |||
15 16 17 18 19 20 21 22 23 24 25 26 27 28 | * file. */ #import "OFValue.h" OF_ASSUME_NONNULL_BEGIN @interface OFNonretainedObjectValue: OFValue { id _object; } @end OF_ASSUME_NONNULL_END | > | 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 | * file. */ #import "OFValue.h" OF_ASSUME_NONNULL_BEGIN OF_SUBCLASSING_RESTRICTED @interface OFNonretainedObjectValue: OFValue { id _object; } @end OF_ASSUME_NONNULL_END |
Modified src/OFNumber.h from [3047242909] to [1367656c87].
︙ | ︙ | |||
112 113 114 115 116 117 118 119 120 121 122 123 124 125 | } of_number_type_t; /*! * @class OFNumber OFNumber.h ObjFW/OFNumber.h * * @brief Provides a way to store a number in an object. */ @interface OFNumber: OFValue <OFComparing, OFSerialization, OFJSONRepresentation, OFMessagePackRepresentation> { union of_number_value { bool bool_; signed char sChar; signed short sShort; | > | 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 | } of_number_type_t; /*! * @class OFNumber OFNumber.h ObjFW/OFNumber.h * * @brief Provides a way to store a number in an object. */ OF_SUBCLASSING_RESTRICTED @interface OFNumber: OFValue <OFComparing, OFSerialization, OFJSONRepresentation, OFMessagePackRepresentation> { union of_number_value { bool bool_; signed char sChar; signed short sShort; |
︙ | ︙ |
Modified src/OFObject.h from [81f633ed2d] to [b3d6515614].
︙ | ︙ | |||
468 469 470 471 472 473 474 | * * Each time an object is released, the retain count gets decreased and the * object deallocated if it reaches 0. */ - (void)release; /*! | | | 468 469 470 471 472 473 474 475 476 477 478 479 480 481 482 | * * Each time an object is released, the retain count gets decreased and the * object deallocated if it reaches 0. */ - (void)release; /*! * @brief Adds the object to the topmost autorelease pool of the thread's * autorelease pool stack. * * @return The object */ - (instancetype)autorelease; /*! |
︙ | ︙ |
Modified src/OFOptionsParser.h from [7b666b9bba] to [9b4ca8e1fd].
︙ | ︙ | |||
62 63 64 65 66 67 68 69 70 71 72 73 74 75 | } of_options_parser_option_t; /*! * @class OFOptionsParser OFOptionsParser.h ObjFW/OFOptionsParser.h * * @brief A class for parsing the program options specified on the command line. */ @interface OFOptionsParser: OFObject { of_options_parser_option_t *_options; OFMapTable *_longOptions; OFArray OF_GENERIC(OFString *) *_arguments; size_t _index, _subIndex; of_unichar_t _lastOption; | > | 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 | } of_options_parser_option_t; /*! * @class OFOptionsParser OFOptionsParser.h ObjFW/OFOptionsParser.h * * @brief A class for parsing the program options specified on the command line. */ OF_SUBCLASSING_RESTRICTED @interface OFOptionsParser: OFObject { of_options_parser_option_t *_options; OFMapTable *_longOptions; OFArray OF_GENERIC(OFString *) *_arguments; size_t _index, _subIndex; of_unichar_t _lastOption; |
︙ | ︙ |
Modified src/OFPair.h from [a91c3b2a6f] to [cd107d57db].
︙ | ︙ | |||
29 30 31 32 33 34 35 36 37 38 39 40 41 42 | #if !defined(OF_HAVE_GENERICS) && !defined(DOXYGEN) # define FirstType id # define SecondType id #endif { FirstType _Nullable _firstObject; SecondType _Nullable _secondObject; } /*! * @brief The first object of the pair. */ @property OF_NULLABLE_PROPERTY (readonly, nonatomic, retain) FirstType firstObject; | > | 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 | #if !defined(OF_HAVE_GENERICS) && !defined(DOXYGEN) # define FirstType id # define SecondType id #endif { FirstType _Nullable _firstObject; SecondType _Nullable _secondObject; OF_RESERVE_IVARS(4) } /*! * @brief The first object of the pair. */ @property OF_NULLABLE_PROPERTY (readonly, nonatomic, retain) FirstType firstObject; |
︙ | ︙ |
Modified src/OFPlugin.h from [82c185a058] to [cb3a1304f8].
︙ | ︙ | |||
37 38 39 40 41 42 43 44 45 46 47 48 49 50 | * @class OFPlugin OFPlugin.h ObjFW/OFPlugin.h * * @brief Provides a system for loading plugins at runtime. */ @interface OFPlugin: OFObject { of_plugin_handle_t _handle; } /*! * @brief Loads a plugin from a file. * * @param path Path to the plugin file. The suffix is appended automatically. * @return The loaded plugin | > | 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 | * @class OFPlugin OFPlugin.h ObjFW/OFPlugin.h * * @brief Provides a system for loading plugins at runtime. */ @interface OFPlugin: OFObject { of_plugin_handle_t _handle; OF_RESERVE_IVARS(4) } /*! * @brief Loads a plugin from a file. * * @param path Path to the plugin file. The suffix is appended automatically. * @return The loaded plugin |
︙ | ︙ |
Modified src/OFPointValue.h from [ee56f0af65] to [88e07dfeed].
︙ | ︙ | |||
15 16 17 18 19 20 21 22 23 24 25 26 27 28 | * file. */ #import "OFValue.h" OF_ASSUME_NONNULL_BEGIN @interface OFPointValue: OFValue { of_point_t _point; } @end OF_ASSUME_NONNULL_END | > | 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 | * file. */ #import "OFValue.h" OF_ASSUME_NONNULL_BEGIN OF_SUBCLASSING_RESTRICTED @interface OFPointValue: OFValue { of_point_t _point; } @end OF_ASSUME_NONNULL_END |
Modified src/OFPointerValue.h from [c394de6a61] to [bc4ae528fd].
︙ | ︙ | |||
15 16 17 18 19 20 21 22 23 24 25 26 27 28 | * file. */ #import "OFValue.h" OF_ASSUME_NONNULL_BEGIN @interface OFPointerValue: OFValue { void *_pointer; } @end OF_ASSUME_NONNULL_END | > | 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 | * file. */ #import "OFValue.h" OF_ASSUME_NONNULL_BEGIN OF_SUBCLASSING_RESTRICTED @interface OFPointerValue: OFValue { void *_pointer; } @end OF_ASSUME_NONNULL_END |
Modified src/OFPollKernelEventObserver.h from [aa8c14235f] to [2770775881].
︙ | ︙ | |||
17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 | #import "OFKernelEventObserver.h" OF_ASSUME_NONNULL_BEGIN @class OFMutableData; @interface OFPollKernelEventObserver: OFKernelEventObserver { OFMutableData *_FDs; int _maxFD; id __unsafe_unretained *_FDToObject; } @end OF_ASSUME_NONNULL_END | > | 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 | #import "OFKernelEventObserver.h" OF_ASSUME_NONNULL_BEGIN @class OFMutableData; OF_SUBCLASSING_RESTRICTED @interface OFPollKernelEventObserver: OFKernelEventObserver { OFMutableData *_FDs; int _maxFD; id __unsafe_unretained *_FDToObject; } @end OF_ASSUME_NONNULL_END |
Modified src/OFProcess.h from [7c50dd3a7c] to [df8e9272e3].
︙ | ︙ | |||
42 43 44 45 46 47 48 49 50 51 52 53 54 55 | @class OFDictionary OF_GENERIC(KeyType, ObjectType); /*! * @class OFProcess OFProcess.h ObjFW/OFProcess.h * * @brief A class for stream-like communication with a newly created process. */ @interface OFProcess: OFStream #ifndef OF_WINDOWS <OFReadyForReadingObserving, OFReadyForWritingObserving> #endif { #ifndef OF_WINDOWS pid_t _pid; | > | 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 | @class OFDictionary OF_GENERIC(KeyType, ObjectType); /*! * @class OFProcess OFProcess.h ObjFW/OFProcess.h * * @brief A class for stream-like communication with a newly created process. */ OF_SUBCLASSING_RESTRICTED @interface OFProcess: OFStream #ifndef OF_WINDOWS <OFReadyForReadingObserving, OFReadyForWritingObserving> #endif { #ifndef OF_WINDOWS pid_t _pid; |
︙ | ︙ |
Modified src/OFRIPEMD160Hash.h from [4b27eef996] to [8064412ceb].
︙ | ︙ | |||
22 23 24 25 26 27 28 29 30 31 32 33 34 35 | @class OFSecureData; /*! * @class OFRIPEMD160Hash OFRIPEMD160Hash.h ObjFW/OFRIPEMD160Hash.h * * @brief A class which provides methods to create a RIPEMD-160 hash. */ @interface OFRIPEMD160Hash: OFObject <OFCryptoHash> { OFSecureData *_iVarsData; struct of_ripemd160_hash_ivars { uint32_t state[5]; uint64_t bits; union of_ripemd160_hash_buffer { | > | 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 | @class OFSecureData; /*! * @class OFRIPEMD160Hash OFRIPEMD160Hash.h ObjFW/OFRIPEMD160Hash.h * * @brief A class which provides methods to create a RIPEMD-160 hash. */ OF_SUBCLASSING_RESTRICTED @interface OFRIPEMD160Hash: OFObject <OFCryptoHash> { OFSecureData *_iVarsData; struct of_ripemd160_hash_ivars { uint32_t state[5]; uint64_t bits; union of_ripemd160_hash_buffer { |
︙ | ︙ |
Modified src/OFRangeCharacterSet.h from [d6286761a3] to [a2771ad1c7].
︙ | ︙ | |||
15 16 17 18 19 20 21 22 23 24 25 26 27 28 | * file. */ #import "OFCharacterSet.h" OF_ASSUME_NONNULL_BEGIN @interface OFRangeCharacterSet: OFCharacterSet { of_range_t _range; } @end OF_ASSUME_NONNULL_END | > | 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 | * file. */ #import "OFCharacterSet.h" OF_ASSUME_NONNULL_BEGIN OF_SUBCLASSING_RESTRICTED @interface OFRangeCharacterSet: OFCharacterSet { of_range_t _range; } @end OF_ASSUME_NONNULL_END |
Modified src/OFRangeValue.h from [485fced595] to [a8ef163be5].
︙ | ︙ | |||
15 16 17 18 19 20 21 22 23 24 25 26 27 28 | * file. */ #import "OFValue.h" OF_ASSUME_NONNULL_BEGIN @interface OFRangeValue: OFValue { of_range_t _range; } @end OF_ASSUME_NONNULL_END | > | 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 | * file. */ #import "OFValue.h" OF_ASSUME_NONNULL_BEGIN OF_SUBCLASSING_RESTRICTED @interface OFRangeValue: OFValue { of_range_t _range; } @end OF_ASSUME_NONNULL_END |
Modified src/OFRectangleValue.h from [e6635df87d] to [7066e1a221].
︙ | ︙ | |||
15 16 17 18 19 20 21 22 23 24 25 26 27 28 | * file. */ #import "OFValue.h" OF_ASSUME_NONNULL_BEGIN @interface OFRectangleValue: OFValue { of_rectangle_t _rectangle; } @end OF_ASSUME_NONNULL_END | > | 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 | * file. */ #import "OFValue.h" OF_ASSUME_NONNULL_BEGIN OF_SUBCLASSING_RESTRICTED @interface OFRectangleValue: OFValue { of_rectangle_t _rectangle; } @end OF_ASSUME_NONNULL_END |
Modified src/OFRecursiveMutex.h from [f3a0853f17] to [14cd0ab792].
︙ | ︙ | |||
24 25 26 27 28 29 30 31 32 33 34 35 36 37 | /*! * @class OFRecursiveMutex OFRecursiveMutex.h ObjFW/OFRecursiveMutex.h * * @brief A class for creating mutual exclusions which can be entered * recursively. */ @interface OFRecursiveMutex: OFObject <OFLocking> { of_rmutex_t _rmutex; bool _initialized; OFString *_Nullable _name; } | > | 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 | /*! * @class OFRecursiveMutex OFRecursiveMutex.h ObjFW/OFRecursiveMutex.h * * @brief A class for creating mutual exclusions which can be entered * recursively. */ OF_SUBCLASSING_RESTRICTED @interface OFRecursiveMutex: OFObject <OFLocking> { of_rmutex_t _rmutex; bool _initialized; OFString *_Nullable _name; } |
︙ | ︙ |
Modified src/OFRunLoop.h from [0ba22fa5da] to [93da873991].
︙ | ︙ | |||
55 56 57 58 59 60 61 62 63 64 65 66 67 68 | #endif /*! * @class OFRunLoop OFRunLoop.h ObjFW/OFRunLoop.h * * @brief A class providing a run loop for the application and its processes. */ @interface OFRunLoop: OFObject { OFMutableDictionary *_states; #ifdef OF_HAVE_THREADS OFMutex *_statesMutex; #endif of_run_loop_mode_t _Nullable _currentMode; | > | 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 | #endif /*! * @class OFRunLoop OFRunLoop.h ObjFW/OFRunLoop.h * * @brief A class providing a run loop for the application and its processes. */ OF_SUBCLASSING_RESTRICTED @interface OFRunLoop: OFObject { OFMutableDictionary *_states; #ifdef OF_HAVE_THREADS OFMutex *_statesMutex; #endif of_run_loop_mode_t _Nullable _currentMode; |
︙ | ︙ |
Modified src/OFSHA1Hash.h from [76484e9b92] to [f45a134709].
︙ | ︙ | |||
22 23 24 25 26 27 28 29 30 31 32 33 34 35 | @class OFSecureData; /*! * @class OFSHA1Hash OFSHA1Hash.h ObjFW/OFSHA1Hash.h * * @brief A class which provides methods to create an SHA-1 hash. */ @interface OFSHA1Hash: OFObject <OFCryptoHash> { OFSecureData *_iVarsData; struct of_sha1_hash_ivars { uint32_t state[5]; uint64_t bits; union of_sha1_hash_buffer { | > | 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 | @class OFSecureData; /*! * @class OFSHA1Hash OFSHA1Hash.h ObjFW/OFSHA1Hash.h * * @brief A class which provides methods to create an SHA-1 hash. */ OF_SUBCLASSING_RESTRICTED @interface OFSHA1Hash: OFObject <OFCryptoHash> { OFSecureData *_iVarsData; struct of_sha1_hash_ivars { uint32_t state[5]; uint64_t bits; union of_sha1_hash_buffer { |
︙ | ︙ |
Modified src/OFSHA224Hash.h from [7b625d5901] to [02668ec72c].
︙ | ︙ | |||
20 21 22 23 24 25 26 27 28 29 30 | OF_ASSUME_NONNULL_BEGIN /*! * @class OFSHA224Hash OFSHA224Hash.h ObjFW/OFSHA224Hash.h * * @brief A class which provides methods to create an SHA-224 hash. */ @interface OFSHA224Hash: OFSHA224Or256Hash @end OF_ASSUME_NONNULL_END | > | 20 21 22 23 24 25 26 27 28 29 30 31 | OF_ASSUME_NONNULL_BEGIN /*! * @class OFSHA224Hash OFSHA224Hash.h ObjFW/OFSHA224Hash.h * * @brief A class which provides methods to create an SHA-224 hash. */ OF_SUBCLASSING_RESTRICTED @interface OFSHA224Hash: OFSHA224Or256Hash @end OF_ASSUME_NONNULL_END |
Modified src/OFSHA224Or256Hash.h from [0e59b3265f] to [6b1a277f58].
︙ | ︙ | |||
35 36 37 38 39 40 41 42 43 44 45 | union of_sha224_or_256_hash_buffer { uint8_t bytes[64]; uint32_t words[64]; } buffer; size_t bufferLength; } *_iVars; bool _calculated; } @end OF_ASSUME_NONNULL_END | > | 35 36 37 38 39 40 41 42 43 44 45 46 | union of_sha224_or_256_hash_buffer { uint8_t bytes[64]; uint32_t words[64]; } buffer; size_t bufferLength; } *_iVars; bool _calculated; OF_RESERVE_IVARS(4) } @end OF_ASSUME_NONNULL_END |
Modified src/OFSHA256Hash.h from [1b677ced7a] to [4c62059a65].
︙ | ︙ | |||
20 21 22 23 24 25 26 27 28 29 30 | OF_ASSUME_NONNULL_BEGIN /*! * @class OFSHA256Hash OFSHA256Hash.h ObjFW/OFSHA256Hash.h * * @brief A class which provides methods to create an SHA-256 hash. */ @interface OFSHA256Hash: OFSHA224Or256Hash @end OF_ASSUME_NONNULL_END | > | 20 21 22 23 24 25 26 27 28 29 30 31 | OF_ASSUME_NONNULL_BEGIN /*! * @class OFSHA256Hash OFSHA256Hash.h ObjFW/OFSHA256Hash.h * * @brief A class which provides methods to create an SHA-256 hash. */ OF_SUBCLASSING_RESTRICTED @interface OFSHA256Hash: OFSHA224Or256Hash @end OF_ASSUME_NONNULL_END |
Modified src/OFSHA384Hash.h from [b462056b6f] to [4e1fe029f7].
︙ | ︙ | |||
20 21 22 23 24 25 26 27 28 29 30 | OF_ASSUME_NONNULL_BEGIN /*! * @class OFSHA384Hash OFSHA384Hash.h ObjFW/OFSHA384Hash.h * * @brief A class which provides methods to create an SHA-384 hash. */ @interface OFSHA384Hash: OFSHA384Or512Hash @end OF_ASSUME_NONNULL_END | > | 20 21 22 23 24 25 26 27 28 29 30 31 | OF_ASSUME_NONNULL_BEGIN /*! * @class OFSHA384Hash OFSHA384Hash.h ObjFW/OFSHA384Hash.h * * @brief A class which provides methods to create an SHA-384 hash. */ OF_SUBCLASSING_RESTRICTED @interface OFSHA384Hash: OFSHA384Or512Hash @end OF_ASSUME_NONNULL_END |
Modified src/OFSHA384Or512Hash.h from [da5458033a] to [835b1d3d02].
︙ | ︙ | |||
35 36 37 38 39 40 41 42 43 44 45 | union of_sha384_or_512_hash_buffer { uint8_t bytes[128]; uint64_t words[80]; } buffer; size_t bufferLength; } *_iVars; bool _calculated; } @end OF_ASSUME_NONNULL_END | > | 35 36 37 38 39 40 41 42 43 44 45 46 | union of_sha384_or_512_hash_buffer { uint8_t bytes[128]; uint64_t words[80]; } buffer; size_t bufferLength; } *_iVars; bool _calculated; OF_RESERVE_IVARS(4) } @end OF_ASSUME_NONNULL_END |
Modified src/OFSHA512Hash.h from [763c1dc3e0] to [cfed575886].
︙ | ︙ | |||
20 21 22 23 24 25 26 27 28 29 30 | OF_ASSUME_NONNULL_BEGIN /*! * @class OFSHA512Hash OFSHA512Hash.h ObjFW/OFSHA512Hash.h * * @brief A class which provides methods to create an SHA-512 hash. */ @interface OFSHA512Hash: OFSHA384Or512Hash @end OF_ASSUME_NONNULL_END | > | 20 21 22 23 24 25 26 27 28 29 30 31 | OF_ASSUME_NONNULL_BEGIN /*! * @class OFSHA512Hash OFSHA512Hash.h ObjFW/OFSHA512Hash.h * * @brief A class which provides methods to create an SHA-512 hash. */ OF_SUBCLASSING_RESTRICTED @interface OFSHA512Hash: OFSHA384Or512Hash @end OF_ASSUME_NONNULL_END |
Modified src/OFSandbox.h from [091d297073] to [d6216c6849].
︙ | ︙ | |||
67 68 69 70 71 72 73 74 75 76 77 78 79 80 | unsigned int _allowsAudio: 1; unsigned int _allowsBPF: 1; unsigned int _allowsUnveil: 1; unsigned int _returnsErrors: 1; OFMutableArray OF_GENERIC(of_sandbox_unveil_path_t) *_unveiledPaths; @public size_t _unveiledPathsIndex; } /*! * @brief Allows IO operations on previously allocated file descriptors. */ @property (nonatomic) bool allowsStdIO; | > | 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 | unsigned int _allowsAudio: 1; unsigned int _allowsBPF: 1; unsigned int _allowsUnveil: 1; unsigned int _returnsErrors: 1; OFMutableArray OF_GENERIC(of_sandbox_unveil_path_t) *_unveiledPaths; @public size_t _unveiledPathsIndex; OF_RESERVE_IVARS(4) } /*! * @brief Allows IO operations on previously allocated file descriptors. */ @property (nonatomic) bool allowsStdIO; |
︙ | ︙ |
Modified src/OFSecureData.h from [6b81b595f7] to [4b4455fb4b].
︙ | ︙ | |||
24 25 26 27 28 29 30 31 32 33 34 35 36 37 | * * @brief A class for storing arbitrary data in secure memory, securely wiping * it when it gets deallocated. * * @note Secure memory might be unavailable on the platform, in which case this * falls back to insecure (potentially swappable) memory. */ @interface OFSecureData: OFData { struct page *_page; } #ifdef OF_HAVE_CLASS_PROPERTIES @property (class, readonly, nonatomic, getter=isSecure) bool secure; | > | 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 | * * @brief A class for storing arbitrary data in secure memory, securely wiping * it when it gets deallocated. * * @note Secure memory might be unavailable on the platform, in which case this * falls back to insecure (potentially swappable) memory. */ OF_SUBCLASSING_RESTRICTED @interface OFSecureData: OFData { struct page *_page; } #ifdef OF_HAVE_CLASS_PROPERTIES @property (class, readonly, nonatomic, getter=isSecure) bool secure; |
︙ | ︙ |
Modified src/OFSeekableStream.h from [369226960c] to [acb8ac2896].
︙ | ︙ | |||
52 53 54 55 56 57 58 59 60 61 62 63 64 65 | * @note If you want to subclass this, override * @ref lowlevelSeekToOffset:whence:. OFSeekableStream uses this method * and makes it work together with the caching of OFStream. If you * override this methods without the `lowlevel` prefix, you *will* break * caching, get broken results and seek to the wrong position! */ @interface OFSeekableStream: OFStream /*! * @brief Seeks to the specified absolute offset. * * @param offset The offset in bytes * @param whence From where to seek.@n * Possible values are: * Value | Description | > > > > | 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 | * @note If you want to subclass this, override * @ref lowlevelSeekToOffset:whence:. OFSeekableStream uses this method * and makes it work together with the caching of OFStream. If you * override this methods without the `lowlevel` prefix, you *will* break * caching, get broken results and seek to the wrong position! */ @interface OFSeekableStream: OFStream { OF_RESERVE_IVARS(4) } /*! * @brief Seeks to the specified absolute offset. * * @param offset The offset in bytes * @param whence From where to seek.@n * Possible values are: * Value | Description |
︙ | ︙ |
Modified src/OFSelectKernelEventObserver.h from [4637ad2ef9] to [e8ee327775].
︙ | ︙ | |||
28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 | # include <sys/select.h> #endif #import "OFKernelEventObserver.h" OF_ASSUME_NONNULL_BEGIN @interface OFSelectKernelEventObserver: OFKernelEventObserver { fd_set _readFDs, _writeFDs; int _maxFD; } @end OF_ASSUME_NONNULL_END | > | 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 | # include <sys/select.h> #endif #import "OFKernelEventObserver.h" OF_ASSUME_NONNULL_BEGIN OF_SUBCLASSING_RESTRICTED @interface OFSelectKernelEventObserver: OFKernelEventObserver { fd_set _readFDs, _writeFDs; int _maxFD; } @end OF_ASSUME_NONNULL_END |
Modified src/OFSet.h from [9f71c62224] to [f80d14d494].
︙ | ︙ | |||
65 66 67 68 69 70 71 72 73 74 75 76 77 78 | * @ref objectEnumerator. */ @interface OFSet OF_GENERIC(ObjectType): OFObject <OFCollection, OFCopying, OFMutableCopying, OFSerialization> #if !defined(OF_HAVE_GENERICS) && !defined(DOXYGEN) # define ObjectType id #endif /*! * @brief An array of all objects in the set. */ @property (readonly, nonatomic) OFArray OF_GENERIC(ObjectType) *allObjects; /*! * @brief An arbitrary object in the set. | > > > > | 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 | * @ref objectEnumerator. */ @interface OFSet OF_GENERIC(ObjectType): OFObject <OFCollection, OFCopying, OFMutableCopying, OFSerialization> #if !defined(OF_HAVE_GENERICS) && !defined(DOXYGEN) # define ObjectType id #endif { OF_RESERVE_IVARS(4) } /*! * @brief An array of all objects in the set. */ @property (readonly, nonatomic) OFArray OF_GENERIC(ObjectType) *allObjects; /*! * @brief An arbitrary object in the set. |
︙ | ︙ |
Modified src/OFSettings.h from [aeeac74626] to [cc56f332fa].
︙ | ︙ | |||
32 33 34 35 36 37 38 39 40 41 42 43 44 45 | * for a path, remove it and then set it with the new type. * * @brief A class for storing and retrieving settings */ @interface OFSettings: OFObject { OFString *_applicationName; } /*! * @brief The name of the application whose settings are accessed by the * instance. */ @property (readonly, nonatomic) OFString *applicationName; | > | 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 | * for a path, remove it and then set it with the new type. * * @brief A class for storing and retrieving settings */ @interface OFSettings: OFObject { OFString *_applicationName; OF_RESERVE_IVARS(4) } /*! * @brief The name of the application whose settings are accessed by the * instance. */ @property (readonly, nonatomic) OFString *applicationName; |
︙ | ︙ |
Modified src/OFSortedList.h from [cacefbad95] to [9bfd1b9f4d].
︙ | ︙ | |||
27 28 29 30 31 32 33 34 35 36 37 38 39 40 | * @warning Because the list is sorted, all methods inserting an object at a * specific place are unavailable, even though they exist in OFList! */ @interface OFSortedList OF_GENERIC(ObjectType): OFList OF_GENERIC(ObjectType) #if !defined(OF_HAVE_GENERICS) && !defined(DOXYGEN) # define ObjectType id #endif - (of_list_object_t *)appendObject: (ObjectType)object OF_UNAVAILABLE; - (of_list_object_t *)prependObject: (ObjectType)object OF_UNAVAILABLE; - (of_list_object_t *)insertObject: (ObjectType)object beforeListObject: (of_list_object_t *)listObject OF_UNAVAILABLE; - (of_list_object_t *)insertObject: (ObjectType)object afterListObject: (of_list_object_t *)listObject | > > > > | 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 | * @warning Because the list is sorted, all methods inserting an object at a * specific place are unavailable, even though they exist in OFList! */ @interface OFSortedList OF_GENERIC(ObjectType): OFList OF_GENERIC(ObjectType) #if !defined(OF_HAVE_GENERICS) && !defined(DOXYGEN) # define ObjectType id #endif { OF_RESERVE_IVARS(4) } - (of_list_object_t *)appendObject: (ObjectType)object OF_UNAVAILABLE; - (of_list_object_t *)prependObject: (ObjectType)object OF_UNAVAILABLE; - (of_list_object_t *)insertObject: (ObjectType)object beforeListObject: (of_list_object_t *)listObject OF_UNAVAILABLE; - (of_list_object_t *)insertObject: (ObjectType)object afterListObject: (of_list_object_t *)listObject |
︙ | ︙ |
Modified src/OFStream.h from [437fb045ff] to [b92e531fc2].
︙ | ︙ | |||
202 203 204 205 206 207 208 209 210 211 212 213 214 215 | char *_Nullable _readBuffer, *_Nullable _readBufferMemory; char *_Nullable _writeBuffer; size_t _readBufferLength, _writeBufferLength; bool _writeBuffered, _waitingForDelimiter; @protected bool _blocking; id _Nullable _delegate; } /*! * @brief Whether the end of the stream has been reached. */ @property (readonly, nonatomic, getter=isAtEndOfStream) bool atEndOfStream; | > | 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 | char *_Nullable _readBuffer, *_Nullable _readBufferMemory; char *_Nullable _writeBuffer; size_t _readBufferLength, _writeBufferLength; bool _writeBuffered, _waitingForDelimiter; @protected bool _blocking; id _Nullable _delegate; OF_RESERVE_IVARS(4) } /*! * @brief Whether the end of the stream has been reached. */ @property (readonly, nonatomic, getter=isAtEndOfStream) bool atEndOfStream; |
︙ | ︙ | |||
278 279 280 281 282 283 284 | #ifdef OF_HAVE_SOCKETS /*! * @brief Asynchronously reads *at most* size bytes from the stream into a * buffer. * * On network streams, this might read less than the specified number of bytes. * If you want to read exactly the specified number of bytes, use | | | | | | | | | | | | | | | | 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 306 307 308 309 310 311 312 313 314 315 316 317 318 319 320 321 322 323 324 325 326 327 328 329 330 331 332 333 334 335 336 337 338 339 340 341 342 343 344 345 346 347 348 349 350 351 352 353 354 355 356 357 | #ifdef OF_HAVE_SOCKETS /*! * @brief Asynchronously reads *at most* size bytes from the stream into a * buffer. * * On network streams, this might read less than the specified number of bytes. * If you want to read exactly the specified number of bytes, use * @ref asyncReadIntoBuffer:exactLength:. Note that a read can even return 0 * bytes - this does not necessarily mean that the stream ended, so you still * need to check @ref atEndOfStream. * * @note The stream must conform to @ref OFReadyForReadingObserving in order * for this to work! * * @param buffer The buffer into which the data is read. * The buffer must not be freed before the async read completed! * @param length The length of the data that should be read at most. * The buffer *must* be *at least* this big! */ - (void)asyncReadIntoBuffer: (void *)buffer length: (size_t)length; /*! * @brief Asynchronously reads *at most* size bytes from the stream into a * buffer. * * On network streams, this might read less than the specified number of bytes. * If you want to read exactly the specified number of bytes, use * @ref asyncReadIntoBuffer:exactLength:. Note that a read can even return 0 * bytes - this does not necessarily mean that the stream ended, so you still * need to check @ref atEndOfStream. * * @note The stream must conform to @ref OFReadyForReadingObserving in order * for this to work! * * @param buffer The buffer into which the data is read. * The buffer must not be freed before the async read completed! * @param length The length of the data that should be read at most. * The buffer *must* be *at least* this big! * @param runLoopMode The run loop mode in which to perform the async read */ - (void)asyncReadIntoBuffer: (void *)buffer length: (size_t)length runLoopMode: (of_run_loop_mode_t)runLoopMode; /*! * @brief Asynchronously reads exactly the specified length bytes from the * stream into a buffer. * * Unlike @ref asyncReadIntoBuffer:length:, this method does not call the * method when less than the specified length has been read - instead, it waits * until it got exactly the specified length, the stream has ended or an * exception occurred. * * @note The stream must conform to @ref OFReadyForReadingObserving in order * for this to work! * * @param buffer The buffer into which the data is read * @param length The length of the data that should be read. * The buffer *must* be *at least* this big! */ - (void)asyncReadIntoBuffer: (void *)buffer exactLength: (size_t)length; /*! * @brief Asynchronously reads exactly the specified length bytes from the * stream into a buffer. * * Unlike @ref asyncReadIntoBuffer:length:, this method does not call the * method when less than the specified length has been read - instead, it waits * until it got exactly the specified length, the stream has ended or an * exception occurred. * * @note The stream must conform to @ref OFReadyForReadingObserving in order * for this to work! * * @param buffer The buffer into which the data is read * @param length The length of the data that should be read. * The buffer *must* be *at least* this big! |
︙ | ︙ |
Modified src/OFStreamSocket.h from [830fed3178] to [3403a64f01].
︙ | ︙ | |||
27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 | * @brief A class which provides methods to create and use stream sockets. */ @interface OFStreamSocket: OFStream <OFReadyForReadingObserving, OFReadyForWritingObserving> { of_socket_t _socket; bool _atEndOfStream; } /*! * @brief Returns a new, autoreleased OFTCPSocket. * * @return A new, autoreleased OFTCPSocket */ + (instancetype)socket; @end OF_ASSUME_NONNULL_END | > | 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 | * @brief A class which provides methods to create and use stream sockets. */ @interface OFStreamSocket: OFStream <OFReadyForReadingObserving, OFReadyForWritingObserving> { of_socket_t _socket; bool _atEndOfStream; OF_RESERVE_IVARS(4) } /*! * @brief Returns a new, autoreleased OFTCPSocket. * * @return A new, autoreleased OFTCPSocket */ + (instancetype)socket; @end OF_ASSUME_NONNULL_END |
Modified src/OFString.h from [122f8a653b] to [6ace318746].
︙ | ︙ | |||
117 118 119 120 121 122 123 124 125 126 127 128 129 130 | /*! * @class OFString OFString.h ObjFW/OFString.h * * @brief A class for handling strings. */ @interface OFString: OFObject <OFCopying, OFMutableCopying, OFComparing, OFSerialization, OFJSONRepresentation, OFMessagePackRepresentation> /*! * @brief The length of the string in Unicode codepoints. */ @property (readonly, nonatomic) size_t length; /*! * @brief The OFString as a UTF-8 encoded C string. | > > > > | 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 | /*! * @class OFString OFString.h ObjFW/OFString.h * * @brief A class for handling strings. */ @interface OFString: OFObject <OFCopying, OFMutableCopying, OFComparing, OFSerialization, OFJSONRepresentation, OFMessagePackRepresentation> { OF_RESERVE_IVARS(4) } /*! * @brief The length of the string in Unicode codepoints. */ @property (readonly, nonatomic) size_t length; /*! * @brief The OFString as a UTF-8 encoded C string. |
︙ | ︙ |
Modified src/OFSystemInfo.h from [147dae58c0] to [5361d8dc79].
︙ | ︙ | |||
21 22 23 24 25 26 27 28 29 30 31 32 33 34 | OF_ASSUME_NONNULL_BEGIN /*! * @class OFSystemInfo OFSystemInfo.h ObjFW/OFSystemInfo.h * * @brief A class for querying information about the system. */ @interface OFSystemInfo: OFObject #ifdef OF_HAVE_CLASS_PROPERTIES @property (class, readonly, nonatomic) size_t pageSize; @property (class, readonly, nonatomic) size_t numberOfCPUs; @property (class, readonly, nonatomic) OFString *ObjFWVersion; @property (class, readonly, nonatomic) unsigned int ObjFWVersionMajor; @property (class, readonly, nonatomic) unsigned int ObjFWVersionMinor; | > | 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 | OF_ASSUME_NONNULL_BEGIN /*! * @class OFSystemInfo OFSystemInfo.h ObjFW/OFSystemInfo.h * * @brief A class for querying information about the system. */ OF_SUBCLASSING_RESTRICTED @interface OFSystemInfo: OFObject #ifdef OF_HAVE_CLASS_PROPERTIES @property (class, readonly, nonatomic) size_t pageSize; @property (class, readonly, nonatomic) size_t numberOfCPUs; @property (class, readonly, nonatomic) OFString *ObjFWVersion; @property (class, readonly, nonatomic) unsigned int ObjFWVersionMajor; @property (class, readonly, nonatomic) unsigned int ObjFWVersionMinor; |
︙ | ︙ |
Modified src/OFTCPSocket.h from [0da62ee227] to [52ed0f333c].
︙ | ︙ | |||
100 101 102 103 104 105 106 107 108 109 110 111 112 113 | bool _listening; of_socket_address_t _remoteAddress; OFString *_Nullable _SOCKS5Host; uint16_t _SOCKS5Port; #ifdef OF_WII uint16_t _port; #endif } #ifdef OF_HAVE_CLASS_PROPERTIES @property (class, nullable, copy, nonatomic) OFString *SOCKS5Host; @property (class, nonatomic) uint16_t SOCKS5Port; #endif | > | 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 | bool _listening; of_socket_address_t _remoteAddress; OFString *_Nullable _SOCKS5Host; uint16_t _SOCKS5Port; #ifdef OF_WII uint16_t _port; #endif OF_RESERVE_IVARS(4) } #ifdef OF_HAVE_CLASS_PROPERTIES @property (class, nullable, copy, nonatomic) OFString *SOCKS5Host; @property (class, nonatomic) uint16_t SOCKS5Port; #endif |
︙ | ︙ |
Modified src/OFTarArchive.h from [c1cedd4497] to [499d4e1e00].
︙ | ︙ | |||
25 26 27 28 29 30 31 32 33 34 35 36 37 38 | @class OFStream; /*! * @class OFTarArchive OFTarArchive.h ObjFW/OFTarArchive.h * * @brief A class for accessing and manipulating tar archives. */ @interface OFTarArchive: OFObject { OFStream *_stream; enum { OF_TAR_ARCHIVE_MODE_READ, OF_TAR_ARCHIVE_MODE_WRITE, OF_TAR_ARCHIVE_MODE_APPEND | > | 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 | @class OFStream; /*! * @class OFTarArchive OFTarArchive.h ObjFW/OFTarArchive.h * * @brief A class for accessing and manipulating tar archives. */ OF_SUBCLASSING_RESTRICTED @interface OFTarArchive: OFObject { OFStream *_stream; enum { OF_TAR_ARCHIVE_MODE_READ, OF_TAR_ARCHIVE_MODE_WRITE, OF_TAR_ARCHIVE_MODE_APPEND |
︙ | ︙ |
Modified src/OFTarArchiveEntry.h from [280263548d] to [7184d9b8e2].
︙ | ︙ | |||
57 58 59 60 61 62 63 64 65 66 67 68 69 70 | uint64_t _size; uint32_t _UID, _GID; OFDate *_modificationDate; of_tar_archive_entry_type_t _type; OFString *_Nullable _targetFileName; OFString *_Nullable _owner, *_Nullable _group; uint32_t _deviceMajor, _deviceMinor; } /*! * @brief The file name of the entry. */ @property (readonly, copy, nonatomic) OFString *fileName; | > | 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 | uint64_t _size; uint32_t _UID, _GID; OFDate *_modificationDate; of_tar_archive_entry_type_t _type; OFString *_Nullable _targetFileName; OFString *_Nullable _owner, *_Nullable _group; uint32_t _deviceMajor, _deviceMinor; OF_RESERVE_IVARS(4) } /*! * @brief The file name of the entry. */ @property (readonly, copy, nonatomic) OFString *fileName; |
︙ | ︙ |
Modified src/OFThread.h from [f2bf600216] to [156e47b532].
︙ | ︙ | |||
49 50 51 52 53 54 55 | * @brief A class which provides portable threads. * * To use it, you should create a new class derived from it and reimplement * main. * * @warning Some operating systems such as AmigaOS need special per-thread * initialization of sockets. If you intend to use sockets in the | | | | 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 | * @brief A class which provides portable threads. * * To use it, you should create a new class derived from it and reimplement * main. * * @warning Some operating systems such as AmigaOS need special per-thread * initialization of sockets. If you intend to use sockets in the * thread, set the @ref supportsSockets property to true before * starting it. * * @warning Even though the OFCopying protocol is implemented, it does *not* * return an independent copy of the thread, but instead retains it. * This is so that the thread can be used as a key for a dictionary, * so context can be associated with a thread. */ @interface OFThread: OFObject |
︙ | ︙ | |||
86 87 88 89 90 91 92 93 94 95 96 97 98 99 | OFRunLoop *_Nullable _runLoop; OFMutableDictionary *_threadDictionary; @private OFString *_Nullable _name; # ifdef OF_HAVE_SOCKETS OFDNSResolver *_DNSResolver; # endif } #endif #ifdef OF_HAVE_CLASS_PROPERTIES # ifdef OF_HAVE_THREADS @property (class, readonly, nullable, nonatomic) OFThread *currentThread; @property (class, readonly, nullable, nonatomic) OFThread *mainThread; | > | 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 | OFRunLoop *_Nullable _runLoop; OFMutableDictionary *_threadDictionary; @private OFString *_Nullable _name; # ifdef OF_HAVE_SOCKETS OFDNSResolver *_DNSResolver; # endif OF_RESERVE_IVARS(4) } #endif #ifdef OF_HAVE_CLASS_PROPERTIES # ifdef OF_HAVE_THREADS @property (class, readonly, nullable, nonatomic) OFThread *currentThread; @property (class, readonly, nullable, nonatomic) OFThread *mainThread; |
︙ | ︙ |
Modified src/OFThread.m from [0dae234b3c] to [3758706d1f].
︙ | ︙ | |||
47 48 49 50 51 52 53 | #ifdef OF_NINTENDO_3DS # include <3ds/svc.h> #endif #import "OFThread.h" #import "OFThread+Private.h" | < < | 47 48 49 50 51 52 53 54 55 56 57 58 59 60 | #ifdef OF_NINTENDO_3DS # include <3ds/svc.h> #endif #import "OFThread.h" #import "OFThread+Private.h" #import "OFDate.h" #import "OFDictionary.h" #ifdef OF_HAVE_SOCKETS # import "OFDNSResolver.h" #endif #import "OFLocale.h" #import "OFRunLoop.h" |
︙ | ︙ | |||
133 134 135 136 137 138 139 | # endif thread->_returnValue = [[thread main] retain]; } [thread handleTermination]; objc_autoreleasePoolPop(thread->_pool); | < | 131 132 133 134 135 136 137 138 139 140 141 142 143 144 | # endif thread->_returnValue = [[thread main] retain]; } [thread handleTermination]; objc_autoreleasePoolPop(thread->_pool); #if defined(OF_AMIGAOS) && defined(OF_HAVE_SOCKETS) if (thread.supportsSockets) of_socket_deinit(); #endif thread->_running = OF_THREAD_WAITING_FOR_JOIN; |
︙ | ︙ |
Modified src/OFThreadPool.h from [881b26bdcb] to [a9d1ed6153].
︙ | ︙ | |||
37 38 39 40 41 42 43 44 45 46 47 48 49 50 | * @class OFThreadPool OFThreadPool.h ObjFW/OFThreadPool.h * * @brief A class providing a pool of reusable threads. * * @note When the thread pool is released, all threads will terminate after * they finish the job they are currently processing. */ @interface OFThreadPool: OFObject { size_t _size; OFMutableArray *_threads; volatile int _count; #ifdef OF_THREAD_POOL_M @public | > | 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 | * @class OFThreadPool OFThreadPool.h ObjFW/OFThreadPool.h * * @brief A class providing a pool of reusable threads. * * @note When the thread pool is released, all threads will terminate after * they finish the job they are currently processing. */ OF_SUBCLASSING_RESTRICTED @interface OFThreadPool: OFObject { size_t _size; OFMutableArray *_threads; volatile int _count; #ifdef OF_THREAD_POOL_M @public |
︙ | ︙ |
Modified src/OFTimer.h from [4f5a514bed] to [2f31460f3b].
︙ | ︙ | |||
38 39 40 41 42 43 44 45 46 47 48 49 50 51 | #endif /*! * @class OFTimer OFTimer.h ObjFW/OFTimer.h * * @brief A class for creating and firing timers. */ @interface OFTimer: OFObject <OFComparing> { OFDate *_fireDate; of_time_interval_t _interval; id _target; id _Nullable _object1, _object2, _object3, _object4; SEL _selector; | > | 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 | #endif /*! * @class OFTimer OFTimer.h ObjFW/OFTimer.h * * @brief A class for creating and firing timers. */ OF_SUBCLASSING_RESTRICTED @interface OFTimer: OFObject <OFComparing> { OFDate *_fireDate; of_time_interval_t _interval; id _target; id _Nullable _object1, _object2, _object3, _object4; SEL _selector; |
︙ | ︙ |
Modified src/OFTriple.h from [b9adc8ff29] to [a3365ec37e].
︙ | ︙ | |||
31 32 33 34 35 36 37 38 39 40 41 42 43 44 | # define SecondType id # define ThirdType id #endif { FirstType _Nullable _firstObject; SecondType _Nullable _secondObject; ThirdType _Nullable _thirdObject; } /*! * @brief The first object of the triple. */ @property OF_NULLABLE_PROPERTY (readonly, nonatomic, retain) FirstType firstObject; | > | 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 | # define SecondType id # define ThirdType id #endif { FirstType _Nullable _firstObject; SecondType _Nullable _secondObject; ThirdType _Nullable _thirdObject; OF_RESERVE_IVARS(4) } /*! * @brief The first object of the triple. */ @property OF_NULLABLE_PROPERTY (readonly, nonatomic, retain) FirstType firstObject; |
︙ | ︙ |
Modified src/OFUDPSocket.h from [7aa018221e] to [93eb5b4287].
︙ | ︙ | |||
121 122 123 124 125 126 127 128 129 130 131 132 133 134 | { of_socket_t _socket; #ifdef OF_WII uint16_t _port; #endif bool _blocking; id _Nullable _delegate; } /*! * @brief Whether the socket is in blocking mode. * * By default, a socket is in blocking mode. */ | > | 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 | { of_socket_t _socket; #ifdef OF_WII uint16_t _port; #endif bool _blocking; id _Nullable _delegate; OF_RESERVE_IVARS(4) } /*! * @brief Whether the socket is in blocking mode. * * By default, a socket is in blocking mode. */ |
︙ | ︙ |
Modified src/OFURL.h from [d5f7b8d500] to [6489d1ac08].
︙ | ︙ | |||
33 34 35 36 37 38 39 40 41 42 43 44 45 46 | @interface OFURL: OFObject <OFCopying, OFMutableCopying, OFSerialization> { OFString *_Nullable _URLEncodedScheme, *_Nullable _URLEncodedHost; OFNumber *_Nullable _port; OFString *_Nullable _URLEncodedUser, *_Nullable _URLEncodedPassword; OFString *_Nullable _URLEncodedPath; OFString *_Nullable _URLEncodedQuery, *_Nullable _URLEncodedFragment; } /*! * @brief The scheme part of the URL. */ @property OF_NULLABLE_PROPERTY (readonly, copy, nonatomic) OFString *scheme; | > | 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 | @interface OFURL: OFObject <OFCopying, OFMutableCopying, OFSerialization> { OFString *_Nullable _URLEncodedScheme, *_Nullable _URLEncodedHost; OFNumber *_Nullable _port; OFString *_Nullable _URLEncodedUser, *_Nullable _URLEncodedPassword; OFString *_Nullable _URLEncodedPath; OFString *_Nullable _URLEncodedQuery, *_Nullable _URLEncodedFragment; OF_RESERVE_IVARS(4) } /*! * @brief The scheme part of the URL. */ @property OF_NULLABLE_PROPERTY (readonly, copy, nonatomic) OFString *scheme; |
︙ | ︙ |
Modified src/OFURLHandler.h from [99d8a7ec4d] to [21e47d991e].
︙ | ︙ | |||
30 31 32 33 34 35 36 37 38 39 40 41 42 43 | * @class OFURLHandler OFURLHandler.h ObjFW/OFURLHandler.h * * @brief A handler for a URL scheme. */ @interface OFURLHandler: OFObject { OFString *_scheme; } /*! * @brief The scheme this OFURLHandler handles. */ @property (readonly, nonatomic) OFString *scheme; | > | 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 | * @class OFURLHandler OFURLHandler.h ObjFW/OFURLHandler.h * * @brief A handler for a URL scheme. */ @interface OFURLHandler: OFObject { OFString *_scheme; OF_RESERVE_IVARS(4) } /*! * @brief The scheme this OFURLHandler handles. */ @property (readonly, nonatomic) OFString *scheme; |
︙ | ︙ |
Modified src/OFValue.h from [08334bde30] to [cd088af64e].
︙ | ︙ | |||
21 22 23 24 25 26 27 28 29 30 31 32 33 34 | /*! * @class OFValue OFValue.h ObjFW/OFValue.h * * @brief A class for storing arbitrary values in an object. */ @interface OFValue: OFObject <OFCopying> /*! * @brief The ObjC type encoding of the value. */ @property (readonly, nonatomic) const char *objCType; /*! * @brief The value as a pointer to void. | > > > > | 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 | /*! * @class OFValue OFValue.h ObjFW/OFValue.h * * @brief A class for storing arbitrary values in an object. */ @interface OFValue: OFObject <OFCopying> { OF_RESERVE_IVARS(4) } /*! * @brief The ObjC type encoding of the value. */ @property (readonly, nonatomic) const char *objCType; /*! * @brief The value as a pointer to void. |
︙ | ︙ |
Modified src/OFWin32ConsoleStdIOStream.h from [f6d4919bb8] to [4f43803fd9].
︙ | ︙ | |||
17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 | #define OF_STDIO_STREAM_WIN32CONSOLE_H #import "OFStdIOStream.h" OF_ASSUME_NONNULL_BEGIN @interface OFWin32ConsoleStdIOStream: OFStdIOStream { HANDLE _handle; of_char16_t _incompleteUTF16Surrogate; char _incompleteUTF8Surrogate[4]; size_t _incompleteUTF8SurrogateLen; } @end OF_ASSUME_NONNULL_END | > | 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 | #define OF_STDIO_STREAM_WIN32CONSOLE_H #import "OFStdIOStream.h" OF_ASSUME_NONNULL_BEGIN OF_SUBCLASSING_RESTRICTED @interface OFWin32ConsoleStdIOStream: OFStdIOStream { HANDLE _handle; of_char16_t _incompleteUTF16Surrogate; char _incompleteUTF8Surrogate[4]; size_t _incompleteUTF8SurrogateLen; } @end OF_ASSUME_NONNULL_END |
Modified src/OFWindowsRegistryKey.h from [9fac5d4d25] to [11b2db8071].
︙ | ︙ | |||
24 25 26 27 28 29 30 31 32 33 34 35 36 37 | @class OFData; /*! * @class OFWindowsRegistryKey \ * OFWindowsRegistryKey.h ObjFW/OFWindowsRegistryKey.h */ @interface OFWindowsRegistryKey: OFObject { HKEY _hKey; bool _close; } /*! | > | 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 | @class OFData; /*! * @class OFWindowsRegistryKey \ * OFWindowsRegistryKey.h ObjFW/OFWindowsRegistryKey.h */ OF_SUBCLASSING_RESTRICTED @interface OFWindowsRegistryKey: OFObject { HKEY _hKey; bool _close; } /*! |
︙ | ︙ |
Modified src/OFXMLAttribute.h from [ed65bcb38c] to [9cd58fd2db].
︙ | ︙ | |||
29 30 31 32 33 34 35 36 37 38 39 40 41 42 | @interface OFXMLAttribute: OFXMLNode { #if defined(OF_XML_ELEMENT_M) || defined(OF_XML_PARSER_M) @public #endif OFString *_name, *_Nullable _namespace, *_stringValue; bool _useDoubleQuotes; } /*! * @brief The name of the attribute. */ @property (readonly, nonatomic) OFString *name; | > | 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 | @interface OFXMLAttribute: OFXMLNode { #if defined(OF_XML_ELEMENT_M) || defined(OF_XML_PARSER_M) @public #endif OFString *_name, *_Nullable _namespace, *_stringValue; bool _useDoubleQuotes; OF_RESERVE_IVARS(4) } /*! * @brief The name of the attribute. */ @property (readonly, nonatomic) OFString *name; |
︙ | ︙ |
Modified src/OFXMLCDATA.h from [55264b0e38] to [6b5be91b20].
︙ | ︙ | |||
23 24 25 26 27 28 29 30 31 32 33 34 35 36 | * @class OFXMLCDATA OFXMLCDATA.h ObjFW/OFXMLCDATA.h * * @brief A class representing XML CDATA. */ @interface OFXMLCDATA: OFXMLNode { OFString *_CDATA; } /*! * @brief Creates a new OFXMLCDATA with the specified string. * * @param string The string value for the CDATA * @return A new OFXMLCDATA | > | 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 | * @class OFXMLCDATA OFXMLCDATA.h ObjFW/OFXMLCDATA.h * * @brief A class representing XML CDATA. */ @interface OFXMLCDATA: OFXMLNode { OFString *_CDATA; OF_RESERVE_IVARS(4) } /*! * @brief Creates a new OFXMLCDATA with the specified string. * * @param string The string value for the CDATA * @return A new OFXMLCDATA |
︙ | ︙ |
Modified src/OFXMLCharacters.h from [5302379b94] to [566e2a1d51].
︙ | ︙ | |||
23 24 25 26 27 28 29 30 31 32 33 34 35 36 | * @class OFXMLCharacters OFXMLCharacters.h ObjFW/OFXMLCharacters.h * * @brief A class representing XML characters. */ @interface OFXMLCharacters: OFXMLNode { OFString *_characters; } /*! * @brief Creates a new OFXMLCharacters with the specified string. * * @param string The string value for the characters * @return A new OFXMLCharacters | > | 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 | * @class OFXMLCharacters OFXMLCharacters.h ObjFW/OFXMLCharacters.h * * @brief A class representing XML characters. */ @interface OFXMLCharacters: OFXMLNode { OFString *_characters; OF_RESERVE_IVARS(4) } /*! * @brief Creates a new OFXMLCharacters with the specified string. * * @param string The string value for the characters * @return A new OFXMLCharacters |
︙ | ︙ |
Modified src/OFXMLComment.h from [cff55f0a1f] to [7604b96e68].
︙ | ︙ | |||
23 24 25 26 27 28 29 30 31 32 33 34 35 36 | * @class OFXMLComment OFXMLComment.h ObjFW/OFXMLComment.h * * @brief A class for representing XML comments. */ @interface OFXMLComment: OFXMLNode { OFString *_comment; } /*! * @brief Creates a new OFXMLComment with the specified string. * * @param string The string for the comment * @return A new OFXMLComment | > | 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 | * @class OFXMLComment OFXMLComment.h ObjFW/OFXMLComment.h * * @brief A class for representing XML comments. */ @interface OFXMLComment: OFXMLNode { OFString *_comment; OF_RESERVE_IVARS(4) } /*! * @brief Creates a new OFXMLComment with the specified string. * * @param string The string for the comment * @return A new OFXMLComment |
︙ | ︙ |
Modified src/OFXMLElement.h from [cae7cd646e] to [8a18eb088f].
︙ | ︙ | |||
34 35 36 37 38 39 40 41 42 43 44 45 46 47 | @interface OFXMLElement: OFXMLNode { OFString *_name, *_Nullable _namespace, *_Nullable _defaultNamespace; OFMutableArray OF_GENERIC(OFXMLAttribute *) *_Nullable _attributes; OFMutableDictionary OF_GENERIC(OFString *, OFString *) *_Nullable _namespaces; OFMutableArray OF_GENERIC(OFXMLNode *) *_Nullable _children; } /*! * @brief The name of the element. */ @property (copy, nonatomic) OFString *name; | > | 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 | @interface OFXMLElement: OFXMLNode { OFString *_name, *_Nullable _namespace, *_Nullable _defaultNamespace; OFMutableArray OF_GENERIC(OFXMLAttribute *) *_Nullable _attributes; OFMutableDictionary OF_GENERIC(OFString *, OFString *) *_Nullable _namespaces; OFMutableArray OF_GENERIC(OFXMLNode *) *_Nullable _children; OF_RESERVE_IVARS(4) } /*! * @brief The name of the element. */ @property (copy, nonatomic) OFString *name; |
︙ | ︙ |
Modified src/OFXMLElementBuilder.h from [636accb67a] to [a5bfbc9534].
︙ | ︙ | |||
100 101 102 103 104 105 106 107 108 109 110 111 112 113 | * @brief A class implementing the OFXMLParserDelegate protocol that can build * OFXMLElements from the document parsed by the OFXMLParser. * * It can also be used to build OFXMLElements from parts of the document by * first parsing stuff using the OFXMLParser with another delegate and then * setting the OFXMLElementBuilder as delegate for the parser. */ @interface OFXMLElementBuilder: OFObject <OFXMLParserDelegate> { OFMutableArray OF_GENERIC(OFXMLElement *) *_stack; id <OFXMLElementBuilderDelegate> _Nullable _delegate; } /*! | > | 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 | * @brief A class implementing the OFXMLParserDelegate protocol that can build * OFXMLElements from the document parsed by the OFXMLParser. * * It can also be used to build OFXMLElements from parts of the document by * first parsing stuff using the OFXMLParser with another delegate and then * setting the OFXMLElementBuilder as delegate for the parser. */ OF_SUBCLASSING_RESTRICTED @interface OFXMLElementBuilder: OFObject <OFXMLParserDelegate> { OFMutableArray OF_GENERIC(OFXMLElement *) *_stack; id <OFXMLElementBuilderDelegate> _Nullable _delegate; } /*! |
︙ | ︙ |
Modified src/OFXMLNode.h from [cba2a7e188] to [81d926c432].
︙ | ︙ | |||
24 25 26 27 28 29 30 31 32 33 34 35 36 37 | /*! * @class OFXMLNode OFXMLNode.h ObjFW/OFXMLNode.h * * @brief A class which stores an XML element. */ @interface OFXMLNode: OFObject <OFCopying, OFSerialization> /*! * @brief The contents of the node as a string value. * * For an @ref OFXMLElement, setting it removes all children and creates a * single child with the specified string value. */ @property (nonatomic, copy) OFString *stringValue; | > > > > | 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 | /*! * @class OFXMLNode OFXMLNode.h ObjFW/OFXMLNode.h * * @brief A class which stores an XML element. */ @interface OFXMLNode: OFObject <OFCopying, OFSerialization> { OF_RESERVE_IVARS(4) } /*! * @brief The contents of the node as a string value. * * For an @ref OFXMLElement, setting it removes all children and creates a * single child with the specified string value. */ @property (nonatomic, copy) OFString *stringValue; |
︙ | ︙ |
Modified src/OFXMLParser.h from [7ff9022fef] to [76cd96268b].
︙ | ︙ | |||
125 126 127 128 129 130 131 132 133 134 135 136 137 138 | * @class OFXMLParser OFXMLParser.h ObjFW/OFXMLParser.h * * @brief An event-based XML parser. * * OFXMLParser is an event-based XML parser which calls the delegate's callbacks * as soon as it finds something, thus suitable for streams as well. */ @interface OFXMLParser: OFObject { id <OFXMLParserDelegate> _Nullable _delegate; enum of_xml_parser_state { OF_XMLPARSER_IN_BYTE_ORDER_MARK, OF_XMLPARSER_OUTSIDE_TAG, OF_XMLPARSER_TAG_OPENED, | > | 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 | * @class OFXMLParser OFXMLParser.h ObjFW/OFXMLParser.h * * @brief An event-based XML parser. * * OFXMLParser is an event-based XML parser which calls the delegate's callbacks * as soon as it finds something, thus suitable for streams as well. */ OF_SUBCLASSING_RESTRICTED @interface OFXMLParser: OFObject { id <OFXMLParserDelegate> _Nullable _delegate; enum of_xml_parser_state { OF_XMLPARSER_IN_BYTE_ORDER_MARK, OF_XMLPARSER_OUTSIDE_TAG, OF_XMLPARSER_TAG_OPENED, |
︙ | ︙ |
Modified src/OFXMLProcessingInstructions.h from [3daafe52e9] to [8c87d1c2de].
︙ | ︙ | |||
24 25 26 27 28 29 30 31 32 33 34 35 36 37 | * OFXMLProcessingInstructions.h ObjFW/OFXMLProcessingInstructions.h * * @brief A class for representing XML processing instructions. */ @interface OFXMLProcessingInstructions: OFXMLNode { OFString *_processingInstructions; } /*! * @brief Creates a new OFXMLProcessingInstructions with the specified string. * * @param string The string for the processing instructions * @return A new OFXMLProcessingInstructions | > | 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 | * OFXMLProcessingInstructions.h ObjFW/OFXMLProcessingInstructions.h * * @brief A class for representing XML processing instructions. */ @interface OFXMLProcessingInstructions: OFXMLNode { OFString *_processingInstructions; OF_RESERVE_IVARS(4) } /*! * @brief Creates a new OFXMLProcessingInstructions with the specified string. * * @param string The string for the processing instructions * @return A new OFXMLProcessingInstructions |
︙ | ︙ |
Modified src/OFZIPArchive.h from [4b0bcbe6e5] to [f47223fd79].
︙ | ︙ | |||
27 28 29 30 31 32 33 34 35 36 37 38 39 40 | @class OFStream; /*! * @class OFZIPArchive OFZIPArchive.h ObjFW/OFZIPArchive.h * * @brief A class for accessing and manipulating ZIP files. */ @interface OFZIPArchive: OFObject { OFStream *_stream; int64_t _offset; enum { OF_ZIP_ARCHIVE_MODE_READ, OF_ZIP_ARCHIVE_MODE_WRITE, | > | 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 | @class OFStream; /*! * @class OFZIPArchive OFZIPArchive.h ObjFW/OFZIPArchive.h * * @brief A class for accessing and manipulating ZIP files. */ OF_SUBCLASSING_RESTRICTED @interface OFZIPArchive: OFObject { OFStream *_stream; int64_t _offset; enum { OF_ZIP_ARCHIVE_MODE_READ, OF_ZIP_ARCHIVE_MODE_WRITE, |
︙ | ︙ |
Modified src/OFZIPArchiveEntry.h from [33a9310f4d] to [e9ac584951].
︙ | ︙ | |||
108 109 110 111 112 113 114 115 116 117 118 119 120 121 | OFString *_fileName; OFData *_Nullable _extraField; OFString *_Nullable _fileComment; uint32_t _startDiskNumber; uint16_t _internalAttributes; uint32_t _versionSpecificAttributes; int64_t _localFileHeaderOffset; } /*! * @brief The file name of the entry. */ @property (readonly, copy, nonatomic) OFString *fileName; | > | 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 | OFString *_fileName; OFData *_Nullable _extraField; OFString *_Nullable _fileComment; uint32_t _startDiskNumber; uint16_t _internalAttributes; uint32_t _versionSpecificAttributes; int64_t _localFileHeaderOffset; OF_RESERVE_IVARS(4) } /*! * @brief The file name of the entry. */ @property (readonly, copy, nonatomic) OFString *fileName; |
︙ | ︙ |
Modified src/ObjFW.h from [6fb3e2ce31] to [faf921101f].
︙ | ︙ | |||
14 15 16 17 18 19 20 | * LICENSE.GPLv2 or LICENSE.GPLv3 respectively included in the packaging of this * file. */ #import "OFObject.h" #import "OFBlock.h" | < | 14 15 16 17 18 19 20 21 22 23 24 25 26 27 | * LICENSE.GPLv2 or LICENSE.GPLv3 respectively included in the packaging of this * file. */ #import "OFObject.h" #import "OFBlock.h" #import "OFString.h" #import "OFCharacterSet.h" #import "OFData.h" #import "OFArray.h" #import "OFSecureData.h" |
︙ | ︙ |
Deleted src/foundation-compat.m version [8a3ccfcff7].
|
| < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < |
Modified src/macros.h from [6430489c6f] to [fff954ce5f].
︙ | ︙ | |||
120 121 122 123 124 125 126 127 128 129 130 131 132 133 | # ifdef __BIGGEST_ALIGNMENT__ # define OF_BIGGEST_ALIGNMENT __BIGGEST_ALIGNMENT__ # else # /* Hopefully no arch needs more than 16 byte alignment */ # define OF_BIGGEST_ALIGNMENT 16 # endif #endif #ifdef __GNUC__ # define OF_GCC_VERSION (__GNUC__ * 100 + __GNUC_MINOR__) #else # define OF_GCC_VERSION 0 #endif | > > > > > > > > > > > > > > > | 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 | # ifdef __BIGGEST_ALIGNMENT__ # define OF_BIGGEST_ALIGNMENT __BIGGEST_ALIGNMENT__ # else # /* Hopefully no arch needs more than 16 byte alignment */ # define OF_BIGGEST_ALIGNMENT 16 # endif #endif #define OF_PREPROCESSOR_CONCAT2(a, b) a##b #define OF_PREPROCESSOR_CONCAT(a, b) OF_PREPROCESSOR_CONCAT2(a, b) #if __OBJFW_RUNTIME_ABI__ || (defined(OF_APPLE_RUNTIME) && defined(__OBJC2__)) # define OF_HAVE_NONFRAGILE_IVARS #endif #ifdef OF_HAVE_NONFRAGILE_IVARS # define OF_RESERVE_IVARS(num) #else # define OF_RESERVE_IVARS(num) \ @private \ void *OF_PREPROCESSOR_CONCAT(_reserved, __COUNTER__)[num]; #endif #ifdef __GNUC__ # define OF_GCC_VERSION (__GNUC__ * 100 + __GNUC_MINOR__) #else # define OF_GCC_VERSION 0 #endif |
︙ | ︙ | |||
401 402 403 404 405 406 407 | [self doesNotRecognizeSelector: _cmd]; \ \ abort(); \ \ [super dealloc]; /* Get rid of a stupid warning */ #endif | < < | 416 417 418 419 420 421 422 423 424 425 426 427 428 429 | [self doesNotRecognizeSelector: _cmd]; \ \ abort(); \ \ [super dealloc]; /* Get rid of a stupid warning */ #endif #define OF_CONSTRUCTOR(prio) \ static void __attribute__((__constructor__(prio))) \ OF_PREPROCESSOR_CONCAT(constructor, __LINE__)(void) #define OF_DESTRUCTOR(prio) \ static void __attribute__((__destructor__(prio))) \ OF_PREPROCESSOR_CONCAT(destructor, __LINE__)(void) |
︙ | ︙ |
Modified tests/ForwardingTests.m from [ae1df634f6] to [bd69d2aa63].
︙ | ︙ | |||
176 177 178 179 180 181 182 | return ret; } @end @implementation TestsAppDelegate (ForwardingTests) - (void)forwardingTests { | | | 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 | return ret; } @end @implementation TestsAppDelegate (ForwardingTests) - (void)forwardingTests { void *pool = objc_autoreleasePoolPush(); TEST(@"Forwarding a message and adding a class method", R([ForwardingTest test]) && success && R([ForwardingTest test]) && forwardings == 1); ForwardingTest *t = [[[ForwardingTest alloc] init] autorelease]; |
︙ | ︙ | |||
227 228 229 230 231 232 233 | [t forwardingTargetNilStRetTest]) EXPECT_EXCEPTION(@"-[forwardingTargetForSelector:] self target + " @"stret", OFNotImplementedException, [t forwardingTargetSelfStRetTest]) # endif #endif | | | 227 228 229 230 231 232 233 234 235 236 | [t forwardingTargetNilStRetTest]) EXPECT_EXCEPTION(@"-[forwardingTargetForSelector:] self target + " @"stret", OFNotImplementedException, [t forwardingTargetSelfStRetTest]) # endif #endif objc_autoreleasePoolPop(pool); } @end |
Modified tests/OFArrayTests.m from [501a7abef0] to [54def65eb2].
︙ | ︙ | |||
130 131 132 133 134 135 136 | } @end @implementation TestsAppDelegate (OFArrayTests) - (void)arrayTestsWithClass: (Class)arrayClass mutableClass: (Class)mutableArrayClass { | | | 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 | } @end @implementation TestsAppDelegate (OFArrayTests) - (void)arrayTestsWithClass: (Class)arrayClass mutableClass: (Class)mutableArrayClass { void *pool = objc_autoreleasePoolPush(); OFArray *a[3]; OFMutableArray *m[2]; OFEnumerator *enumerator; id obj; bool ok; size_t i; |
︙ | ︙ | |||
435 436 437 438 439 440 441 | R([m[0] setValue: [OFNumber numberWithShort: 1234] forKey: @"port"]) && [m[0] isEqual: [arrayClass arrayWithObjects: [OFURL URLWithString: @"http://foo.bar:1234/"], [OFURL URLWithString: @"http://bar.qux:1234/"], [OFURL URLWithString: @"http://qux.quxqux:1234/"], nil]]) | | | 435 436 437 438 439 440 441 442 443 444 445 446 447 448 449 450 451 452 453 454 455 | R([m[0] setValue: [OFNumber numberWithShort: 1234] forKey: @"port"]) && [m[0] isEqual: [arrayClass arrayWithObjects: [OFURL URLWithString: @"http://foo.bar:1234/"], [OFURL URLWithString: @"http://bar.qux:1234/"], [OFURL URLWithString: @"http://qux.quxqux:1234/"], nil]]) objc_autoreleasePoolPop(pool); } - (void)arrayTests { module = @"OFArray"; [self arrayTestsWithClass: [SimpleArray class] mutableClass: [SimpleMutableArray class]]; module = @"OFArray_adjacent"; [self arrayTestsWithClass: [OFArray class] mutableClass: [OFMutableArray class]]; } @end |
Modified tests/OFBlockTests.m from [9113c4b9e4] to [6e73d74cf4].
︙ | ︙ | |||
48 49 50 51 52 53 54 | return d; } @implementation TestsAppDelegate (OFBlockTests) - (void)blockTests { | | | 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 | return d; } @implementation TestsAppDelegate (OFBlockTests) - (void)blockTests { void *pool = objc_autoreleasePoolPush(); __block int x; void (^s)(void) = ^ { x = 0; }; void (^m)(void); int (^v)(void); TEST(@"Class of stack block", (Class)&_NSConcreteStackBlock == objc_getClass("OFStackBlock") && |
︙ | ︙ | |||
97 98 99 100 101 102 103 | TEST(@"Autorelease a global block", R([g autorelease])) #ifndef __clang_analyzer__ TEST(@"Autorelease a malloc block", R([m autorelease])) #endif | | | 97 98 99 100 101 102 103 104 105 106 | TEST(@"Autorelease a global block", R([g autorelease])) #ifndef __clang_analyzer__ TEST(@"Autorelease a malloc block", R([m autorelease])) #endif objc_autoreleasePoolPop(pool); } @end |
Modified tests/OFCharacterSetTests.m from [e126da2945] to [32a7feb1cd].
︙ | ︙ | |||
34 35 36 37 38 39 40 | return (character % 2 == 0); } @end @implementation TestsAppDelegate (OFCharacterSetTests) - (void)characterSetTests { | | | 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 | return (character % 2 == 0); } @end @implementation TestsAppDelegate (OFCharacterSetTests) - (void)characterSetTests { void *pool = objc_autoreleasePoolPush(); OFCharacterSet *cs, *ics; bool ok; module = @"OFCharacterSet"; cs = [[[SimpleCharacterSet alloc] init] autorelease]; |
︙ | ︙ | |||
99 100 101 102 103 104 105 | ok = false; } TEST(@"-[invertedSet]", ok); TEST(@"Inverting -[invertedSet] returns original set", ics.invertedSet == cs) | | | 99 100 101 102 103 104 105 106 107 108 | ok = false; } TEST(@"-[invertedSet]", ok); TEST(@"Inverting -[invertedSet] returns original set", ics.invertedSet == cs) objc_autoreleasePoolPop(pool); } @end |
Modified tests/OFDNSResolverTests.m from [f214844b74] to [74c0488932].
︙ | ︙ | |||
20 21 22 23 24 25 26 | #import "TestsAppDelegate.h" static OFString *module = @"OFDNSResolverTests"; @implementation TestsAppDelegate (OFDNSResolverTests) - (void)DNSResolverTests { | | | 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 | #import "TestsAppDelegate.h" static OFString *module = @"OFDNSResolverTests"; @implementation TestsAppDelegate (OFDNSResolverTests) - (void)DNSResolverTests { void *pool = objc_autoreleasePoolPush(); OFDNSResolver *resolver = [OFDNSResolver resolver]; OFMutableString *staticHosts = [OFMutableString string]; for (OFString *host in resolver.staticHosts) { OFString *IPs; if (staticHosts.length > 0) |
︙ | ︙ | |||
57 58 59 60 61 62 63 | resolver.minNumberOfDotsInAbsoluteName); PRINT(GREEN, @"Uses TCP: %u", resolver.usesTCP); PRINT(GREEN, @"Config reload interval: %lf", resolver.configReloadInterval); | | | 57 58 59 60 61 62 63 64 65 66 | resolver.minNumberOfDotsInAbsoluteName); PRINT(GREEN, @"Uses TCP: %u", resolver.usesTCP); PRINT(GREEN, @"Config reload interval: %lf", resolver.configReloadInterval); objc_autoreleasePoolPop(pool); } @end |
Modified tests/OFDataTests.m from [cec219c44a] to [ee44914ba7].
︙ | ︙ | |||
23 24 25 26 27 28 29 | static OFString *module = @"OFData"; const char *str = "Hello!"; @implementation TestsAppDelegate (OFDataTests) - (void)dataTests { | | | 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 | static OFString *module = @"OFData"; const char *str = "Hello!"; @implementation TestsAppDelegate (OFDataTests) - (void)dataTests { void *pool = objc_autoreleasePoolPush(); OFMutableData *mutable; OFData *immutable; void *raw[2]; of_range_t range; TEST(@"+[dataWithItemSize:]", (mutable = [OFMutableData dataWithItemSize: 4096])) |
︙ | ︙ | |||
204 205 206 207 208 209 210 | OFOutOfRangeException, [mutable addItems: raw[0] count: SIZE_MAX]) EXPECT_EXCEPTION(@"Detect out of range in -[removeItemsInRange:]", OFOutOfRangeException, [mutable removeItemsInRange: of_range(mutable.count, 1)]) | | | 204 205 206 207 208 209 210 211 212 213 | OFOutOfRangeException, [mutable addItems: raw[0] count: SIZE_MAX]) EXPECT_EXCEPTION(@"Detect out of range in -[removeItemsInRange:]", OFOutOfRangeException, [mutable removeItemsInRange: of_range(mutable.count, 1)]) objc_autoreleasePoolPop(pool); } @end |
Modified tests/OFDateTests.m from [db640ccf02] to [1d894fc345].
︙ | ︙ | |||
22 23 24 25 26 27 28 | #import "TestsAppDelegate.h" static OFString *module = @"OFDate"; @implementation TestsAppDelegate (OFDateTests) - (void)dateTests { | | | 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 | #import "TestsAppDelegate.h" static OFString *module = @"OFDate"; @implementation TestsAppDelegate (OFDateTests) - (void)dateTests { void *pool = objc_autoreleasePoolPush(); OFDate *d1, *d2; struct tm tm; int16_t tz; const char *dstr = "Wed, 09 Jun 2021 +0200x"; TEST(@"of_strptime()", of_strptime(dstr, "%a, %d %b %Y %z", &tm, &tz) == dstr + 22 && |
︙ | ︙ | |||
95 96 97 98 99 100 101 | TEST(@"-[dayOfYear]", d1.dayOfYear == 1 && d2.dayOfYear == 2) TEST(@"-[earlierDate:]", [[d1 earlierDate: d2] isEqual: d1]) TEST(@"-[laterDate:]", [[d1 laterDate: d2] isEqual: d2]) | | | 95 96 97 98 99 100 101 102 103 104 | TEST(@"-[dayOfYear]", d1.dayOfYear == 1 && d2.dayOfYear == 2) TEST(@"-[earlierDate:]", [[d1 earlierDate: d2] isEqual: d1]) TEST(@"-[laterDate:]", [[d1 laterDate: d2] isEqual: d2]) objc_autoreleasePoolPop(pool); } @end |
Modified tests/OFDictionaryTests.m from [71910a92f2] to [912a668d02].
︙ | ︙ | |||
159 160 161 162 163 164 165 | } @end @implementation TestsAppDelegate (OFDictionaryTests) - (void)dictionaryTestsWithClass: (Class)dictionaryClass mutableClass: (Class)mutableDictionaryClass { | | | 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 | } @end @implementation TestsAppDelegate (OFDictionaryTests) - (void)dictionaryTestsWithClass: (Class)dictionaryClass mutableClass: (Class)mutableDictionaryClass { void *pool = objc_autoreleasePoolPush(); OFMutableDictionary *mutDict = [mutableDictionaryClass dictionary]; OFDictionary *dict; OFEnumerator *keyEnumerator, *objectEnumerator; OFArray *keysArray, *valuesArray; [mutDict setObject: values[0] forKey: keys[0]]; |
︙ | ︙ | |||
380 381 382 383 384 385 386 | TEST(@"-[isEqual:]", ![mutDict isEqual: dict] && R([mutDict removeObjectForKey: @"key3"]) && ![mutDict isEqual: dict] && R([mutDict setObject: values[0] forKey: keys[0]]) && [mutDict isEqual: dict]) | | | 380 381 382 383 384 385 386 387 388 389 390 391 392 393 394 395 396 397 398 399 400 | TEST(@"-[isEqual:]", ![mutDict isEqual: dict] && R([mutDict removeObjectForKey: @"key3"]) && ![mutDict isEqual: dict] && R([mutDict setObject: values[0] forKey: keys[0]]) && [mutDict isEqual: dict]) objc_autoreleasePoolPop(pool); } - (void)dictionaryTests { module = @"OFDictionary"; [self dictionaryTestsWithClass: [SimpleDictionary class] mutableClass: [SimpleMutableDictionary class]]; module = @"OFDictionary_hashtable"; [self dictionaryTestsWithClass: [OFDictionary class] mutableClass: [OFMutableDictionary class]]; } @end |
Modified tests/OFHMACTests.m from [490f0952c5] to [f9913e8e72].
︙ | ︙ | |||
48 49 50 51 52 53 54 | "\xC9\xE1\x1F\xD7\xC7\xE5\x59\x33\xD5\x2F\xAF\x56\x1C\x94\xC8\xA4" "\x61\xB3\xF9\x1A\xE3\x09\x43\xA6\x5B\x85\xB1\x50\x5B\xCB\x1A\x2E" "\xB7\xE8\x87\xC1\x73\x19\x63\xF6\xA2\x91\x8D\x7E\x2E\xCC\xEC\x99"; @implementation TestsAppDelegate (OFHMACTests) - (void)HMACTests { | | | 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 | "\xC9\xE1\x1F\xD7\xC7\xE5\x59\x33\xD5\x2F\xAF\x56\x1C\x94\xC8\xA4" "\x61\xB3\xF9\x1A\xE3\x09\x43\xA6\x5B\x85\xB1\x50\x5B\xCB\x1A\x2E" "\xB7\xE8\x87\xC1\x73\x19\x63\xF6\xA2\x91\x8D\x7E\x2E\xCC\xEC\x99"; @implementation TestsAppDelegate (OFHMACTests) - (void)HMACTests { void *pool = objc_autoreleasePoolPush(); OFFile *f = [OFFile fileWithPath: @"testfile.bin" mode: @"r"]; OFHMAC *HMAC_MD5, *HMAC_SHA1, *HMAC_RMD160; OFHMAC *HMAC_SHA256, *HMAC_SHA384, *HMAC_SHA512; TEST(@"+[HMACWithHashClass:] with MD5", (HMAC_MD5 = [OFHMAC HMACWithHashClass: [OFMD5Hash class]])) |
︙ | ︙ | |||
126 127 128 129 130 131 132 | TEST(@"-[digest] with SHA-384", memcmp(HMAC_SHA384.digest, digest_sha384, HMAC_SHA384.digestSize) == 0) TEST(@"-[digest] with SHA-512", memcmp(HMAC_SHA512.digest, digest_sha512, HMAC_SHA512.digestSize) == 0) | | | 126 127 128 129 130 131 132 133 134 135 | TEST(@"-[digest] with SHA-384", memcmp(HMAC_SHA384.digest, digest_sha384, HMAC_SHA384.digestSize) == 0) TEST(@"-[digest] with SHA-512", memcmp(HMAC_SHA512.digest, digest_sha512, HMAC_SHA512.digestSize) == 0) objc_autoreleasePoolPop(pool); } @end |
Modified tests/OFHTTPClientTests.m from [3c6e718237] to [b66261adb6].
︙ | ︙ | |||
105 106 107 108 109 110 111 | response = [response_ retain]; [[OFRunLoop mainRunLoop] stop]; } - (void)HTTPClientTests { | | | 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 | response = [response_ retain]; [[OFRunLoop mainRunLoop] stop]; } - (void)HTTPClientTests { void *pool = objc_autoreleasePoolPush(); HTTPClientTestsServer *server; OFURL *URL; OFHTTPClient *client; OFHTTPRequest *request; OFData *data; cond = [OFCondition condition]; |
︙ | ︙ | |||
149 150 151 152 153 154 155 | TEST(@"Correct parsing of data", (data = [response readDataUntilEndOfStream]) && data.count == 7 && memcmp(data.items, "foo\nbar", 7) == 0) [server join]; | | | 149 150 151 152 153 154 155 156 157 158 | TEST(@"Correct parsing of data", (data = [response readDataUntilEndOfStream]) && data.count == 7 && memcmp(data.items, "foo\nbar", 7) == 0) [server join]; objc_autoreleasePoolPop(pool); } @end |
Modified tests/OFHTTPCookieManagerTests.m from [1acde59a2a] to [ef05512ace].
︙ | ︙ | |||
20 21 22 23 24 25 26 | #import "TestsAppDelegate.h" static OFString *module = @"OFHTTPCookieManager"; @implementation TestsAppDelegate (OFHTTPCookieManagerTests) - (void)HTTPCookieManagerTests { | | | 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 | #import "TestsAppDelegate.h" static OFString *module = @"OFHTTPCookieManager"; @implementation TestsAppDelegate (OFHTTPCookieManagerTests) - (void)HTTPCookieManagerTests { void *pool = objc_autoreleasePoolPush(); OFHTTPCookieManager *manager = [OFHTTPCookieManager manager]; OFURL *URL[4]; OFHTTPCookie *cookie[5]; URL[0] = [OFURL URLWithString: @"http://heap.zone/foo"]; URL[1] = [OFURL URLWithString: @"https://heap.zone/foo/bar"]; URL[2] = [OFURL URLWithString: @"https://test.heap.zone/foo/bar"]; |
︙ | ︙ | |||
96 97 98 99 100 101 102 | TEST(@"-[purgeExpiredCookies]", [manager.cookies isEqual: [OFArray arrayWithObjects: cookie[2], cookie[3], cookie[4], nil]] && R([manager purgeExpiredCookies]) && [manager.cookies isEqual: [OFArray arrayWithObjects: cookie[3], cookie[4], nil]]) | | | 96 97 98 99 100 101 102 103 104 105 | TEST(@"-[purgeExpiredCookies]", [manager.cookies isEqual: [OFArray arrayWithObjects: cookie[2], cookie[3], cookie[4], nil]] && R([manager purgeExpiredCookies]) && [manager.cookies isEqual: [OFArray arrayWithObjects: cookie[3], cookie[4], nil]]) objc_autoreleasePoolPop(pool); } @end |
Modified tests/OFHTTPCookieTests.m from [d0cc5dd06b] to [352e3e5c35].
︙ | ︙ | |||
20 21 22 23 24 25 26 | #import "TestsAppDelegate.h" static OFString *module = @"OFHTTPCookie"; @implementation TestsAppDelegate (OFHTTPCookieTests) - (void)HTTPCookieTests { | | | 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 | #import "TestsAppDelegate.h" static OFString *module = @"OFHTTPCookie"; @implementation TestsAppDelegate (OFHTTPCookieTests) - (void)HTTPCookieTests { void *pool = objc_autoreleasePoolPush(); OFURL *URL = [OFURL URLWithString: @"http://heap.zone"]; OFHTTPCookie *cookie[2]; OFArray OF_GENERIC(OFHTTPCookie *) *cookies; cookie[0] = [OFHTTPCookie cookieWithName: @"foo" value: @"bar" domain: @"heap.zone"]; |
︙ | ︙ | |||
66 67 68 69 70 71 72 | [OFArray arrayWithObjects: cookie[0], cookie[1], nil]]) TEST(@"+[requestHeaderFieldsWithCookies:]", [[OFHTTPCookie requestHeaderFieldsWithCookies: cookies] isEqual: [OFDictionary dictionaryWithObject: @"foo=bar; qux=cookie" forKey: @"Cookie"]]) | | | 66 67 68 69 70 71 72 73 74 75 | [OFArray arrayWithObjects: cookie[0], cookie[1], nil]]) TEST(@"+[requestHeaderFieldsWithCookies:]", [[OFHTTPCookie requestHeaderFieldsWithCookies: cookies] isEqual: [OFDictionary dictionaryWithObject: @"foo=bar; qux=cookie" forKey: @"Cookie"]]) objc_autoreleasePoolPop(pool); } @end |
Modified tests/OFINIFileTests.m from [9c94f90635] to [3e25a4c2de].
︙ | ︙ | |||
20 21 22 23 24 25 26 | #import "TestsAppDelegate.h" static OFString *module = @"OFINIFile"; @implementation TestsAppDelegate (OFINIFileTests) - (void)INIFileTests { | | | 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 | #import "TestsAppDelegate.h" static OFString *module = @"OFINIFile"; @implementation TestsAppDelegate (OFINIFileTests) - (void)INIFileTests { void *pool = objc_autoreleasePoolPush(); OFString *output = @"[tests]\r\n" @"foo=baz\r\n" @"foobar=baz\r\n" @";comment\r\n" @"new=new\r\n" @"\r\n" @"[foobar]\r\n" |
︙ | ︙ | |||
137 138 139 140 141 142 143 | encoding: OF_STRING_ENCODING_CODEPAGE_437] isEqual: output]) [[OFFileManager defaultManager] removeItemAtPath: writePath]; #else (void)output; #endif | | | 137 138 139 140 141 142 143 144 145 146 | encoding: OF_STRING_ENCODING_CODEPAGE_437] isEqual: output]) [[OFFileManager defaultManager] removeItemAtPath: writePath]; #else (void)output; #endif objc_autoreleasePoolPop(pool); } @end |
Modified tests/OFInvocationTests.m from [d69df80290] to [a893e98c20].
︙ | ︙ | |||
251 252 253 254 255 256 257 | (int)i8 + (int)i9 + (int)i10 + (int)i11 + (int)i12 + (int)i13 + (int)i14 + (int)i15 + (int)i16) / 16) + mask; } #endif - (void)invocationTests { | | | 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 | (int)i8 + (int)i9 + (int)i10 + (int)i11 + (int)i12 + (int)i13 + (int)i14 + (int)i15 + (int)i16) / 16) + mask; } #endif - (void)invocationTests { void *pool = objc_autoreleasePoolPush(); SEL selector = @selector(invocationTestMethod1::::); OFMethodSignature *sig = [self methodSignatureForSelector: selector]; OFInvocation *invocation; struct test_struct st, st2, *stp = &st, *stp2; unsigned const char c = 0xAA; unsigned char c2; const unsigned int i = 0x55555555; |
︙ | ︙ | |||
307 308 309 310 311 312 313 | atIndex: 4]) && stp == stp2) TEST(@"-[getArgument:atIndex:] #4", R([invocation getArgument: &st2 atIndex: 5]) && memcmp(&st, &st2, sizeof(st)) == 0) | | | 307 308 309 310 311 312 313 314 315 316 | atIndex: 4]) && stp == stp2) TEST(@"-[getArgument:atIndex:] #4", R([invocation getArgument: &st2 atIndex: 5]) && memcmp(&st, &st2, sizeof(st)) == 0) objc_autoreleasePoolPop(pool); } @end |
Modified tests/OFJSONTests.m from [d82a70372d] to [f5ca7dab96].
︙ | ︙ | |||
20 21 22 23 24 25 26 | #import "TestsAppDelegate.h" static OFString *module = @"OFJSON"; @implementation TestsAppDelegate (JSONTests) - (void)JSONTests { | | | 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 | #import "TestsAppDelegate.h" static OFString *module = @"OFJSON"; @implementation TestsAppDelegate (JSONTests) - (void)JSONTests { void *pool = objc_autoreleasePoolPush(); OFString *s = @"{\"foo\"\t:'b\\na\\r', \"x\":/*foo*/ [.5\r,0xF,null" @"//bar\n,\"foo\",false]}"; OFDictionary *d = [OFDictionary dictionaryWithKeysAndObjects: @"foo", @"b\na\r", @"x", [OFArray arrayWithObjects: [OFNumber numberWithFloat: .5f], [OFNumber numberWithInt: 0xF], |
︙ | ︙ | |||
81 82 83 84 85 86 87 | [OFArray arrayWithObject: [OFDictionary dictionary]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]) EXPECT_EXCEPTION(@"-[JSONValue] #7", OFInvalidJSONException, [@"[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[{}]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]" JSONValue]) | | | 81 82 83 84 85 86 87 88 89 90 | [OFArray arrayWithObject: [OFDictionary dictionary]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]) EXPECT_EXCEPTION(@"-[JSONValue] #7", OFInvalidJSONException, [@"[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[[{}]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]]" JSONValue]) objc_autoreleasePoolPop(pool); } @end |
Modified tests/OFKernelEventObserverTests.m from [acffe39aa3] to [b7d7784260].
︙ | ︙ | |||
194 195 196 197 198 199 200 | } } @end @implementation TestsAppDelegate (OFKernelEventObserverTests) - (void)kernelEventObserverTestsWithClass: (Class)class { | | | | 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 | } } @end @implementation TestsAppDelegate (OFKernelEventObserverTests) - (void)kernelEventObserverTestsWithClass: (Class)class { void *pool = objc_autoreleasePoolPush(); ObserverTest *test; module = [class className]; test = [[[ObserverTest alloc] initWithTestsAppDelegate: self] autorelease]; TEST(@"+[observer]", (test->_observer = [class observer])) test->_observer.delegate = test; TEST(@"-[addObjectForReading:]", R([test->_observer addObjectForReading: test->_server])) [test run]; _fails += test->_fails; objc_autoreleasePoolPop(pool); } - (void)kernelEventObserverTests { #ifdef HAVE_SELECT [self kernelEventObserverTestsWithClass: [OFSelectKernelEventObserver class]]; |
︙ | ︙ |
Modified tests/OFListTests.m from [0f5664c086] to [a93ef64198].
︙ | ︙ | |||
25 26 27 28 29 30 31 | @"Bar", @"Baz" }; @implementation TestsAppDelegate (OFListTests) - (void)listTests { | | | 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 | @"Bar", @"Baz" }; @implementation TestsAppDelegate (OFListTests) - (void)listTests { void *pool = objc_autoreleasePoolPush(); OFList *list; OFEnumerator *enumerator; of_list_object_t *loe; OFString *obj; size_t i; bool ok; |
︙ | ︙ | |||
142 143 144 145 146 147 148 | } } @catch (OFEnumerationMutationException *e) { ok = true; } TEST(@"Detection of mutation during Fast Enumeration", ok) | | | 142 143 144 145 146 147 148 149 150 151 | } } @catch (OFEnumerationMutationException *e) { ok = true; } TEST(@"Detection of mutation during Fast Enumeration", ok) objc_autoreleasePoolPop(pool); } @end |
Modified tests/OFLocaleTests.m from [692b41d8fd] to [dae2656633].
︙ | ︙ | |||
20 21 22 23 24 25 26 | #import "TestsAppDelegate.h" static OFString *module = @"OFLocale"; @implementation TestsAppDelegate (OFLocaleTests) - (void)localeTests { | | | | 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 | #import "TestsAppDelegate.h" static OFString *module = @"OFLocale"; @implementation TestsAppDelegate (OFLocaleTests) - (void)localeTests { void *pool = objc_autoreleasePoolPush(); PRINT(GREEN, @"Language: %@", [OFLocale language]); PRINT(GREEN, @"Territory: %@", [OFLocale territory]); PRINT(GREEN, @"Encoding: %@", of_string_name_of_encoding([OFLocale encoding])); PRINT(GREEN, @"Decimal point: %@", [OFLocale decimalPoint]); objc_autoreleasePoolPop(pool); } @end |
Modified tests/OFMD5HashTests.m from [c6a6847787] to [f4ae6e53d2].
︙ | ︙ | |||
25 26 27 28 29 30 31 | const uint8_t testfile_md5[16] = "\x00\x8B\x9D\x1B\x58\xDF\xF8\xFE\xEE\xF3\xAE\x8D\xBB\x68\x2D\x38"; @implementation TestsAppDelegate (OFMD5HashTests) - (void)MD5HashTests { | | | 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 | const uint8_t testfile_md5[16] = "\x00\x8B\x9D\x1B\x58\xDF\xF8\xFE\xEE\xF3\xAE\x8D\xBB\x68\x2D\x38"; @implementation TestsAppDelegate (OFMD5HashTests) - (void)MD5HashTests { void *pool = objc_autoreleasePoolPush(); OFMD5Hash *md5, *copy; OFFile *f = [OFFile fileWithPath: @"testfile.bin" mode: @"r"]; TEST(@"+[cryptoHash]", (md5 = [OFMD5Hash cryptoHash])) while (!f.atEndOfStream) { |
︙ | ︙ | |||
52 53 54 55 56 57 58 | memcmp(copy.digest, testfile_md5, 16) == 0) EXPECT_EXCEPTION(@"Detect invalid call of " @"-[updateWithBuffer:length]", OFHashAlreadyCalculatedException, [md5 updateWithBuffer: "" length: 1]) | | | 52 53 54 55 56 57 58 59 60 61 | memcmp(copy.digest, testfile_md5, 16) == 0) EXPECT_EXCEPTION(@"Detect invalid call of " @"-[updateWithBuffer:length]", OFHashAlreadyCalculatedException, [md5 updateWithBuffer: "" length: 1]) objc_autoreleasePoolPop(pool); } @end |
Modified tests/OFMethodSignatureTests.m from [919883130b] to [5611c9beab].
︙ | ︙ | |||
70 71 72 73 74 75 76 | double d; } u; }; @implementation TestsAppDelegate (OFMethodSignatureTests) - (void)methodSignatureTests { | | | 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 | double d; } u; }; @implementation TestsAppDelegate (OFMethodSignatureTests) - (void)methodSignatureTests { void *pool = objc_autoreleasePoolPush(); OFMethodSignature *ms; TEST(@"-[:signatureWithObjCTypes:] #1", (ms = [OFMethodSignature signatureWithObjCTypes: "i28@0:8S16*20"]) && ms.numberOfArguments == 4 && strcmp(ms.methodReturnType, "i") == 0 && strcmp([ms argumentTypeAtIndex: 0], "@") == 0 && |
︙ | ︙ | |||
168 169 170 171 172 173 174 | of_alignof_type_encoding(@encode(union test4_union)) == OF_ALIGNOF(union test4_union)) TEST(@"of_alignof_type_encoding() #6", of_alignof_type_encoding(@encode(struct test1_struct [5])) == OF_ALIGNOF(struct test1_struct [5])) | | | 168 169 170 171 172 173 174 175 176 177 | of_alignof_type_encoding(@encode(union test4_union)) == OF_ALIGNOF(union test4_union)) TEST(@"of_alignof_type_encoding() #6", of_alignof_type_encoding(@encode(struct test1_struct [5])) == OF_ALIGNOF(struct test1_struct [5])) objc_autoreleasePoolPop(pool); } @end |
Modified tests/OFNumberTests.m from [174623645b] to [a12fde05f5].
︙ | ︙ | |||
20 21 22 23 24 25 26 | #import "TestsAppDelegate.h" static OFString *module = @"OFNumber"; @implementation TestsAppDelegate (OFNumberTests) - (void)numberTests { | | | | 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 | #import "TestsAppDelegate.h" static OFString *module = @"OFNumber"; @implementation TestsAppDelegate (OFNumberTests) - (void)numberTests { void *pool = objc_autoreleasePoolPush(); OFNumber *num; TEST(@"+[numberWithIntMax:]", (num = [OFNumber numberWithIntMax: 123456789])) TEST(@"-[isEqual:]", [num isEqual: [OFNumber numberWithUInt32: 123456789]]) TEST(@"-[hash]", num.hash == 0x82D8BC42) TEST(@"-[charValue]", num.charValue == 21) TEST(@"-[doubleValue]", num.doubleValue == 123456789.L) objc_autoreleasePoolPop(pool); } @end |
Modified tests/OFObjectTests.m from [e96462b442] to [24e2594f2c].
︙ | ︙ | |||
82 83 84 85 86 87 88 | [super dealloc]; } @end @implementation TestsAppDelegate (OFObjectTests) - (void)objectTests { | | | 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 | [super dealloc]; } @end @implementation TestsAppDelegate (OFObjectTests) - (void)objectTests { void *pool = objc_autoreleasePoolPush(); OFObject *obj = [[[OFObject alloc] init] autorelease]; void *p, *q, *r; OFObject *o; MyObj *m; char *tmp; TEST(@"Allocating 4096 bytes", |
︙ | ︙ | |||
253 254 255 256 257 258 259 | doubleValue] == 0.5) TEST(@"[-setValue:forKeyPath:]", R([m setValue: [OFNumber numberWithDouble: 0.75] forKeyPath: @"objectValue.objectValue.doubleValue"]) && [[m.objectValue objectValue] doubleValue] == 0.75) | | | 253 254 255 256 257 258 259 260 261 262 | doubleValue] == 0.5) TEST(@"[-setValue:forKeyPath:]", R([m setValue: [OFNumber numberWithDouble: 0.75] forKeyPath: @"objectValue.objectValue.doubleValue"]) && [[m.objectValue objectValue] doubleValue] == 0.75) objc_autoreleasePoolPop(pool); } @end |
Modified tests/OFPluginTests.m from [0b5843a21f] to [4b60027dda].
︙ | ︙ | |||
28 29 30 31 32 33 34 | #endif static OFString *module = @"OFPlugin"; @implementation TestsAppDelegate (OFPluginTests) - (void)pluginTests { | | | | 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 | #endif static OFString *module = @"OFPlugin"; @implementation TestsAppDelegate (OFPluginTests) - (void)pluginTests { void *pool = objc_autoreleasePoolPush(); TestPlugin *plugin; TEST(@"+[pluginFromFile:]", (plugin = [OFPlugin pluginFromFile: PLUGIN_PATH])) TEST(@"TestPlugin's -[test:]", [plugin test: 1234] == 2468) objc_autoreleasePoolPop(pool); } @end |
Modified tests/OFPropertyListTests.m from [9d7de2772c] to [a6db7d83f8].
︙ | ︙ | |||
54 55 56 57 58 59 60 | @" <key>foo</key>" @" <string>bar</string>" @"</dict>"); @implementation TestsAppDelegate (OFPLISTParser) - (void)propertyListTests { | | | 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 | @" <key>foo</key>" @" <string>bar</string>" @"</dict>"); @implementation TestsAppDelegate (OFPLISTParser) - (void)propertyListTests { void *pool = objc_autoreleasePoolPush(); OFArray *array = [OFArray arrayWithObjects: @"Hello", [OFData dataWithItems: "World!" count: 6], [OFDate dateWithTimeIntervalSince1970: 1521030896], [OFNumber numberWithBool: true], [OFNumber numberWithBool: false], |
︙ | ︙ | |||
110 111 112 113 114 115 116 | [PLIST(@"<dict><key/><string/><key/></dict>") propertyListValue]) EXPECT_EXCEPTION( @"-[propertyListValue] detecting invalid format #5", OFInvalidFormatException, [PLIST(@"<dict><key x='x'/><string/></dict>") propertyListValue]) | | | 110 111 112 113 114 115 116 117 118 119 | [PLIST(@"<dict><key/><string/><key/></dict>") propertyListValue]) EXPECT_EXCEPTION( @"-[propertyListValue] detecting invalid format #5", OFInvalidFormatException, [PLIST(@"<dict><key x='x'/><string/></dict>") propertyListValue]) objc_autoreleasePoolPop(pool); } @end |
Modified tests/OFRIPEMD160HashTests.m from [9aaabddcf7] to [0fcea6bf49].
︙ | ︙ | |||
26 27 28 29 30 31 32 | const uint8_t testfile_rmd160[20] = "\x46\x02\x97\xF5\x85\xDF\xB9\x21\x00\xC8\xF9\x87\xC6\xEC\x84\x0D\xCE" "\xE6\x08\x8B"; @implementation TestsAppDelegate (OFRIPEMD160HashTests) - (void)RIPEMD160HashTests { | | | 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 | const uint8_t testfile_rmd160[20] = "\x46\x02\x97\xF5\x85\xDF\xB9\x21\x00\xC8\xF9\x87\xC6\xEC\x84\x0D\xCE" "\xE6\x08\x8B"; @implementation TestsAppDelegate (OFRIPEMD160HashTests) - (void)RIPEMD160HashTests { void *pool = objc_autoreleasePoolPush(); OFRIPEMD160Hash *rmd160, *copy; OFFile *f = [OFFile fileWithPath: @"testfile.bin" mode: @"r"]; TEST(@"+[cryptoHash]", (rmd160 = [OFRIPEMD160Hash cryptoHash])) while (!f.atEndOfStream) { |
︙ | ︙ | |||
53 54 55 56 57 58 59 | memcmp(copy.digest, testfile_rmd160, 20) == 0) EXPECT_EXCEPTION(@"Detect invalid call of " @"-[updateWithBuffer:length]", OFHashAlreadyCalculatedException, [rmd160 updateWithBuffer: "" length: 1]) | | | 53 54 55 56 57 58 59 60 61 62 | memcmp(copy.digest, testfile_rmd160, 20) == 0) EXPECT_EXCEPTION(@"Detect invalid call of " @"-[updateWithBuffer:length]", OFHashAlreadyCalculatedException, [rmd160 updateWithBuffer: "" length: 1]) objc_autoreleasePoolPop(pool); } @end |
Modified tests/OFSHA1HashTests.m from [8145ea23f0] to [24505cc96a].
︙ | ︙ | |||
26 27 28 29 30 31 32 | const uint8_t testfile_sha1[20] = "\xC9\x9A\xB8\x7E\x1E\xC8\xEC\x65\xD5\xEB\xE4\x2E\x0D\xA6\x80\x96\xF5" "\x94\xE7\x17"; @implementation TestsAppDelegate (SHA1HashTests) - (void)SHA1HashTests { | | | 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 | const uint8_t testfile_sha1[20] = "\xC9\x9A\xB8\x7E\x1E\xC8\xEC\x65\xD5\xEB\xE4\x2E\x0D\xA6\x80\x96\xF5" "\x94\xE7\x17"; @implementation TestsAppDelegate (SHA1HashTests) - (void)SHA1HashTests { void *pool = objc_autoreleasePoolPush(); OFSHA1Hash *sha1, *copy; OFFile *f = [OFFile fileWithPath: @"testfile.bin" mode: @"r"]; TEST(@"+[cryptoHash]", (sha1 = [OFSHA1Hash cryptoHash])) while (!f.atEndOfStream) { |
︙ | ︙ | |||
53 54 55 56 57 58 59 | memcmp(copy.digest, testfile_sha1, 20) == 0) EXPECT_EXCEPTION(@"Detect invalid call of " @"-[updateWithBuffer:length:]", OFHashAlreadyCalculatedException, [sha1 updateWithBuffer: "" length: 1]) | | | 53 54 55 56 57 58 59 60 61 62 | memcmp(copy.digest, testfile_sha1, 20) == 0) EXPECT_EXCEPTION(@"Detect invalid call of " @"-[updateWithBuffer:length:]", OFHashAlreadyCalculatedException, [sha1 updateWithBuffer: "" length: 1]) objc_autoreleasePoolPop(pool); } @end |
Modified tests/OFSHA224HashTests.m from [600acd5836] to [892f9e3b00].
︙ | ︙ | |||
26 27 28 29 30 31 32 | const uint8_t testfile_sha224[28] = "\x27\x69\xD8\x04\x2D\x0F\xCA\x84\x6C\xF1\x62\x44\xBA\x0C\xBD\x46\x64" "\x5F\x4F\x20\x02\x4D\x15\xED\x1C\x61\x1F\xF7"; @implementation TestsAppDelegate (SHA224HashTests) - (void)SHA224HashTests { | | | 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 | const uint8_t testfile_sha224[28] = "\x27\x69\xD8\x04\x2D\x0F\xCA\x84\x6C\xF1\x62\x44\xBA\x0C\xBD\x46\x64" "\x5F\x4F\x20\x02\x4D\x15\xED\x1C\x61\x1F\xF7"; @implementation TestsAppDelegate (SHA224HashTests) - (void)SHA224HashTests { void *pool = objc_autoreleasePoolPush(); OFSHA224Hash *sha224, *copy; OFFile *f = [OFFile fileWithPath: @"testfile.bin" mode: @"r"]; TEST(@"+[cryptoHash]", (sha224 = [OFSHA224Hash cryptoHash])) while (!f.atEndOfStream) { |
︙ | ︙ | |||
53 54 55 56 57 58 59 | memcmp(copy.digest, testfile_sha224, 28) == 0) EXPECT_EXCEPTION(@"Detect invalid call of " @"-[updateWithBuffer:length:]", OFHashAlreadyCalculatedException, [sha224 updateWithBuffer: "" length: 1]) | | | 53 54 55 56 57 58 59 60 61 62 | memcmp(copy.digest, testfile_sha224, 28) == 0) EXPECT_EXCEPTION(@"Detect invalid call of " @"-[updateWithBuffer:length:]", OFHashAlreadyCalculatedException, [sha224 updateWithBuffer: "" length: 1]) objc_autoreleasePoolPop(pool); } @end |
Modified tests/OFSHA256HashTests.m from [638be55668] to [56e7b8b3e2].
︙ | ︙ | |||
26 27 28 29 30 31 32 | const uint8_t testfile_sha256[32] = "\x1A\x02\xD6\x46\xF5\xA6\xBA\xAA\xFF\x7F\xD5\x87\xBA\xC3\xF6\xC6\xB5" "\x67\x93\x8F\x0F\x44\x90\xB8\xF5\x35\x89\xF0\x5A\x23\x7F\x69"; @implementation TestsAppDelegate (SHA256HashTests) - (void)SHA256HashTests { | | | 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 | const uint8_t testfile_sha256[32] = "\x1A\x02\xD6\x46\xF5\xA6\xBA\xAA\xFF\x7F\xD5\x87\xBA\xC3\xF6\xC6\xB5" "\x67\x93\x8F\x0F\x44\x90\xB8\xF5\x35\x89\xF0\x5A\x23\x7F\x69"; @implementation TestsAppDelegate (SHA256HashTests) - (void)SHA256HashTests { void *pool = objc_autoreleasePoolPush(); OFSHA256Hash *sha256, *copy; OFFile *f = [OFFile fileWithPath: @"testfile.bin" mode: @"r"]; TEST(@"+[cryptoHash]", (sha256 = [OFSHA256Hash cryptoHash])) while (!f.atEndOfStream) { |
︙ | ︙ | |||
53 54 55 56 57 58 59 | memcmp(copy.digest, testfile_sha256, 32) == 0) EXPECT_EXCEPTION(@"Detect invalid call of " @"-[updateWithBuffer:length:]", OFHashAlreadyCalculatedException, [sha256 updateWithBuffer: "" length: 1]) | | | 53 54 55 56 57 58 59 60 61 62 | memcmp(copy.digest, testfile_sha256, 32) == 0) EXPECT_EXCEPTION(@"Detect invalid call of " @"-[updateWithBuffer:length:]", OFHashAlreadyCalculatedException, [sha256 updateWithBuffer: "" length: 1]) objc_autoreleasePoolPop(pool); } @end |
Modified tests/OFSHA384HashTests.m from [2c33539498] to [2c7782d9c6].
︙ | ︙ | |||
27 28 29 30 31 32 33 | "\x7E\xDE\x62\xE2\x10\xA5\x1E\x18\x8A\x11\x7F\x78\xD7\xC7\x55\xB6\x43" "\x94\x1B\xD2\x78\x5C\xCF\xF3\x8A\xB8\x98\x22\xC7\x0E\xFE\xF1\xEC\x53" "\xE9\x1A\xB3\x51\x70\x8C\x1F\x3F\x56\x12\x44\x01\x91\x54"; @implementation TestsAppDelegate (SHA384HashTests) - (void)SHA384HashTests { | | | 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 | "\x7E\xDE\x62\xE2\x10\xA5\x1E\x18\x8A\x11\x7F\x78\xD7\xC7\x55\xB6\x43" "\x94\x1B\xD2\x78\x5C\xCF\xF3\x8A\xB8\x98\x22\xC7\x0E\xFE\xF1\xEC\x53" "\xE9\x1A\xB3\x51\x70\x8C\x1F\x3F\x56\x12\x44\x01\x91\x54"; @implementation TestsAppDelegate (SHA384HashTests) - (void)SHA384HashTests { void *pool = objc_autoreleasePoolPush(); OFSHA384Hash *sha384, *copy; OFFile *f = [OFFile fileWithPath: @"testfile.bin" mode: @"r"]; TEST(@"+[cryptoHash]", (sha384 = [OFSHA384Hash cryptoHash])) while (!f.atEndOfStream) { |
︙ | ︙ | |||
54 55 56 57 58 59 60 | memcmp(copy.digest, testfile_sha384, 48) == 0) EXPECT_EXCEPTION(@"Detect invalid call of " @"-[updateWithBuffer:length:]", OFHashAlreadyCalculatedException, [sha384 updateWithBuffer: "" length: 1]) | | | 54 55 56 57 58 59 60 61 62 63 | memcmp(copy.digest, testfile_sha384, 48) == 0) EXPECT_EXCEPTION(@"Detect invalid call of " @"-[updateWithBuffer:length:]", OFHashAlreadyCalculatedException, [sha384 updateWithBuffer: "" length: 1]) objc_autoreleasePoolPop(pool); } @end |
Modified tests/OFSHA512HashTests.m from [a22ba9da74] to [24ed9c7de8].
︙ | ︙ | |||
28 29 30 31 32 33 34 | "\x97\x6A\x3F\xEB\x9B\xB2\xCB\x75\xC9\xEC\xC8\x10\x07\xD6\x07\x31\x4A" "\xB1\x30\x97\x82\x58\xA5\x1F\x71\x42\xE6\x56\x07\x99\x57\xB2\xB8\x3B" "\xA1\x8A\x41\x64\x33\x69\x21\x8C\x2A\x44\x6D\xF2\xA0"; @implementation TestsAppDelegate (SHA512HashTests) - (void)SHA512HashTests { | | | 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 | "\x97\x6A\x3F\xEB\x9B\xB2\xCB\x75\xC9\xEC\xC8\x10\x07\xD6\x07\x31\x4A" "\xB1\x30\x97\x82\x58\xA5\x1F\x71\x42\xE6\x56\x07\x99\x57\xB2\xB8\x3B" "\xA1\x8A\x41\x64\x33\x69\x21\x8C\x2A\x44\x6D\xF2\xA0"; @implementation TestsAppDelegate (SHA512HashTests) - (void)SHA512HashTests { void *pool = objc_autoreleasePoolPush(); OFSHA512Hash *sha512, *copy; OFFile *f = [OFFile fileWithPath: @"testfile.bin" mode: @"r"]; TEST(@"+[cryptoHash]", (sha512 = [OFSHA512Hash cryptoHash])) while (!f.atEndOfStream) { |
︙ | ︙ | |||
55 56 57 58 59 60 61 | memcmp(copy.digest, testfile_sha512, 64) == 0) EXPECT_EXCEPTION(@"Detect invalid call of " @"-[updateWithBuffer:length:]", OFHashAlreadyCalculatedException, [sha512 updateWithBuffer: "" length: 1]) | | | 55 56 57 58 59 60 61 62 63 64 | memcmp(copy.digest, testfile_sha512, 64) == 0) EXPECT_EXCEPTION(@"Detect invalid call of " @"-[updateWithBuffer:length:]", OFHashAlreadyCalculatedException, [sha512 updateWithBuffer: "" length: 1]) objc_autoreleasePoolPop(pool); } @end |
Modified tests/OFSerializationTests.m from [80594c127a] to [e8c5cad0b7].
︙ | ︙ | |||
20 21 22 23 24 25 26 | #import "TestsAppDelegate.h" static OFString *module = @"OFSerialization"; @implementation TestsAppDelegate (OFSerializationTests) - (void)serializationTests { | | | 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 | #import "TestsAppDelegate.h" static OFString *module = @"OFSerialization"; @implementation TestsAppDelegate (OFSerializationTests) - (void)serializationTests { void *pool = objc_autoreleasePoolPush(); OFMutableDictionary *d = [OFMutableDictionary dictionary]; OFMutableArray *a = [OFMutableArray array]; OFList *l = [OFList list]; OFData *data; OFString *s; [a addObject: @"Qu\"xbar\ntest"]; |
︙ | ︙ | |||
61 62 63 64 65 66 67 | TEST(@"-[stringBySerializing]", (s = d.stringBySerializing) && [s isEqual: [OFString stringWithContentsOfFile: @"serialization.xml"]]) TEST(@"-[objectByDeserializing]", [s.objectByDeserializing isEqual: d]) | | | 61 62 63 64 65 66 67 68 69 70 | TEST(@"-[stringBySerializing]", (s = d.stringBySerializing) && [s isEqual: [OFString stringWithContentsOfFile: @"serialization.xml"]]) TEST(@"-[objectByDeserializing]", [s.objectByDeserializing isEqual: d]) objc_autoreleasePoolPop(pool); } @end |
Modified tests/OFSetTests.m from [78f1739521] to [cf6c84cec3].
︙ | ︙ | |||
161 162 163 164 165 166 167 | } @end @implementation TestsAppDelegate (OFSetTests) - (void)setTestsWithClass: (Class)setClass mutableClass: (Class)mutableSetClass { | | | 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 | } @end @implementation TestsAppDelegate (OFSetTests) - (void)setTestsWithClass: (Class)setClass mutableClass: (Class)mutableSetClass { void *pool = objc_autoreleasePoolPush(); OFSet *set1, *set2; OFMutableSet *mutableSet; bool ok; size_t i; TEST(@"+[setWithArray:]", (set1 = [setClass setWithArray: [OFArray arrayWithObjects: @"foo", |
︙ | ︙ | |||
279 280 281 282 283 284 285 | [(set1 = [[setClass setWithObjects: @"a", @"ab", @"abc", @"b", nil] valueForKey: @"length"]) isEqual: [setClass setWithObjects: [OFNumber numberWithSize: 1], [OFNumber numberWithSize: 2], [OFNumber numberWithSize: 3], nil]] && [[set1 valueForKey: @"@count"] isEqual: [OFNumber numberWithSize: 3]]) | | | 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 | [(set1 = [[setClass setWithObjects: @"a", @"ab", @"abc", @"b", nil] valueForKey: @"length"]) isEqual: [setClass setWithObjects: [OFNumber numberWithSize: 1], [OFNumber numberWithSize: 2], [OFNumber numberWithSize: 3], nil]] && [[set1 valueForKey: @"@count"] isEqual: [OFNumber numberWithSize: 3]]) objc_autoreleasePoolPop(pool); } - (void)setTests { module = @"OFSet"; [self setTestsWithClass: [SimpleSet class] mutableClass: [SimpleMutableSet class]]; module = @"OFMapTableSet"; [self setTestsWithClass: [OFMapTableSet class] mutableClass: [OFMutableMapTableSet class]]; } @end |
Modified tests/OFStreamTests.m from [21aef18599] to [fe2a783d3f].
︙ | ︙ | |||
61 62 63 64 65 66 67 | return 0; } @end @implementation TestsAppDelegate (OFStreamTests) - (void)streamTests { | | | | 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 | return 0; } @end @implementation TestsAppDelegate (OFStreamTests) - (void)streamTests { void *pool = objc_autoreleasePoolPush(); size_t pageSize = [OFSystemInfo pageSize]; StreamTester *t = [[[StreamTester alloc] init] autorelease]; OFString *str; char *cstr; cstr = [t allocMemoryWithSize: pageSize - 2]; memset(cstr, 'X', pageSize - 3); cstr[pageSize - 3] = '\0'; TEST(@"-[readLine]", [[t readLine] isEqual: @"foo"] && (str = [t readLine]).length == pageSize - 3 && !strcmp(str.UTF8String, cstr)) objc_autoreleasePoolPop(pool); } @end |
Modified tests/OFStringTests.m from [6659b80a48] to [c26219a4ab].
︙ | ︙ | |||
207 208 209 210 211 212 213 | } @end @implementation TestsAppDelegate (OFStringTests) - (void)stringTestsWithClass: (Class)stringClass mutableClass: (Class)mutableStringClass { | | | 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 | } @end @implementation TestsAppDelegate (OFStringTests) - (void)stringTestsWithClass: (Class)stringClass mutableClass: (Class)mutableStringClass { void *pool = objc_autoreleasePoolPush(); OFMutableString *s[3]; OFString *is; OFArray *a; size_t i; const of_unichar_t *ua; const uint16_t *u16a; OFCharacterSet *cs; |
︙ | ︙ | |||
1420 1421 1422 1423 1424 1425 1426 | j++; }]; TEST(@"-[enumerateLinesUsingBlock:]", ok) #endif #undef C | | | 1420 1421 1422 1423 1424 1425 1426 1427 1428 1429 1430 1431 1432 1433 1434 1435 1436 1437 1438 1439 1440 | j++; }]; TEST(@"-[enumerateLinesUsingBlock:]", ok) #endif #undef C objc_autoreleasePoolPop(pool); } - (void)stringTests { module = @"OFString"; [self stringTestsWithClass: [SimpleString class] mutableClass: [SimpleMutableString class]]; module = @"OFString_UTF8"; [self stringTestsWithClass: [OFUTF8String class] mutableClass: [OFMutableUTF8String class]]; } @end |
Modified tests/OFSystemInfoTests.m from [96bd962194] to [893f52f398].
︙ | ︙ | |||
20 21 22 23 24 25 26 | #import "TestsAppDelegate.h" static OFString *module = @"OFSystemInfo"; @implementation TestsAppDelegate (OFSystemInfoTests) - (void)systemInfoTests { | | | 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 | #import "TestsAppDelegate.h" static OFString *module = @"OFSystemInfo"; @implementation TestsAppDelegate (OFSystemInfoTests) - (void)systemInfoTests { void *pool = objc_autoreleasePoolPush(); #ifdef OF_HAVE_FILES OFString *userConfigPath, *userDataPath; #endif PRINT(GREEN, @"Page size: %zd", [OFSystemInfo pageSize]); PRINT(GREEN, @"Number of CPUs: %zd", [OFSystemInfo numberOfCPUs]); |
︙ | ︙ | |||
92 93 94 95 96 97 98 | [OFSystemInfo supportsSHAExtensions]); #endif #ifdef OF_POWERPC PRINT(GREEN, @"Supports AltiVec: %d", [OFSystemInfo supportsAltiVec]); #endif | | | 92 93 94 95 96 97 98 99 100 101 | [OFSystemInfo supportsSHAExtensions]); #endif #ifdef OF_POWERPC PRINT(GREEN, @"Supports AltiVec: %d", [OFSystemInfo supportsAltiVec]); #endif objc_autoreleasePoolPop(pool); } @end |
Modified tests/OFTCPSocketTests.m from [1c451b0231] to [3676496bb6].
︙ | ︙ | |||
22 23 24 25 26 27 28 | #import "TestsAppDelegate.h" static OFString *module = @"OFTCPSocket"; @implementation TestsAppDelegate (OFTCPSocketTests) - (void)TCPSocketTests { | | | 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 | #import "TestsAppDelegate.h" static OFString *module = @"OFTCPSocket"; @implementation TestsAppDelegate (OFTCPSocketTests) - (void)TCPSocketTests { void *pool = objc_autoreleasePoolPush(); OFTCPSocket *server, *client = nil, *accepted; uint16_t port; char buf[6]; TEST(@"+[socket]", (server = [OFTCPSocket socket]) && (client = [OFTCPSocket socket])) |
︙ | ︙ | |||
52 53 54 55 56 57 58 | TEST(@"-[writeString:]", [client writeString: @"Hello!"]) TEST(@"-[readIntoBuffer:length:]", [accepted readIntoBuffer: buf length: 6] && !memcmp(buf, "Hello!", 6)) | | | 52 53 54 55 56 57 58 59 60 61 | TEST(@"-[writeString:]", [client writeString: @"Hello!"]) TEST(@"-[readIntoBuffer:length:]", [accepted readIntoBuffer: buf length: 6] && !memcmp(buf, "Hello!", 6)) objc_autoreleasePoolPop(pool); } @end |
Modified tests/OFThreadTests.m from [fb8f211ca9] to [c49f1dd816].
︙ | ︙ | |||
33 34 35 36 37 38 39 | return @"success"; } @end @implementation TestsAppDelegate (OFThreadTests) - (void)threadTests { | | | | 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 | return @"success"; } @end @implementation TestsAppDelegate (OFThreadTests) - (void)threadTests { void *pool = objc_autoreleasePoolPush(); TestThread *t; OFMutableDictionary *d; TEST(@"+[thread]", (t = [TestThread thread])) TEST(@"-[start]", R([t start])) TEST(@"-[join]", [[t join] isEqual: @"success"]) TEST(@"-[threadDictionary]", (d = [OFThread threadDictionary]) && [d objectForKey: @"foo"] == nil) objc_autoreleasePoolPop(pool); } @end |
Modified tests/OFUDPSocketTests.m from [e01b68cb73] to [a0e1bef0c4].
︙ | ︙ | |||
22 23 24 25 26 27 28 | #import "TestsAppDelegate.h" static OFString *module = @"OFUDPSocket"; @implementation TestsAppDelegate (OFUDPSocketTests) - (void)UDPSocketTests { | | | 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 | #import "TestsAppDelegate.h" static OFString *module = @"OFUDPSocket"; @implementation TestsAppDelegate (OFUDPSocketTests) - (void)UDPSocketTests { void *pool = objc_autoreleasePoolPush(); OFUDPSocket *sock; uint16_t port1, port2; of_socket_address_t addr1, addr2, addr3; char buf[6]; OFString *host; TEST(@"+[socket]", (sock = [OFUDPSocket socket])) |
︙ | ︙ | |||
64 65 66 67 68 69 70 | of_socket_address_equal(&addr1, &addr2) && !of_socket_address_equal(&addr1, &addr3)) TEST(@"of_socket_address_hash()", of_socket_address_hash(&addr1) == of_socket_address_hash(&addr2) && of_socket_address_hash(&addr1) != of_socket_address_hash(&addr3)) | | | 64 65 66 67 68 69 70 71 72 73 | of_socket_address_equal(&addr1, &addr2) && !of_socket_address_equal(&addr1, &addr3)) TEST(@"of_socket_address_hash()", of_socket_address_hash(&addr1) == of_socket_address_hash(&addr2) && of_socket_address_hash(&addr1) != of_socket_address_hash(&addr3)) objc_autoreleasePoolPop(pool); } @end |
Modified tests/OFURLTests.m from [4e831f3a6c] to [8adc5244fa].
︙ | ︙ | |||
22 23 24 25 26 27 28 | static OFString *module = @"OFURL"; static OFString *url_str = @"ht%3atp://us%3Aer:p%40w@ho%3Ast:1234/" @"pa%3Fth?que%23ry#frag%23ment"; @implementation TestsAppDelegate (OFURLTests) - (void)URLTests { | | | 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 | static OFString *module = @"OFURL"; static OFString *url_str = @"ht%3atp://us%3Aer:p%40w@ho%3Ast:1234/" @"pa%3Fth?que%23ry#frag%23ment"; @implementation TestsAppDelegate (OFURLTests) - (void)URLTests { void *pool = objc_autoreleasePoolPush(); OFURL *u1, *u2, *u3, *u4, *u5; OFMutableURL *mu; TEST(@"+[URLWithString:]", R(u1 = [OFURL URLWithString: url_str]) && R(u2 = [OFURL URLWithString: @"http://foo:80"]) && R(u3 = [OFURL URLWithString: @"http://bar/"]) && |
︙ | ︙ | |||
278 279 280 281 282 283 284 | [[[OFURL URLWithString: @"http://foo/bar/./././qux/./"] URLByStandardizingPath] isEqual: [OFURL URLWithString: @"http://foo/bar/qux/"]] && [[[OFURL URLWithString: @"http://foo/bar/../../qux"] URLByStandardizingPath] isEqual: [OFURL URLWithString: @"http://foo/../qux"]]) | | | 278 279 280 281 282 283 284 285 286 287 | [[[OFURL URLWithString: @"http://foo/bar/./././qux/./"] URLByStandardizingPath] isEqual: [OFURL URLWithString: @"http://foo/bar/qux/"]] && [[[OFURL URLWithString: @"http://foo/bar/../../qux"] URLByStandardizingPath] isEqual: [OFURL URLWithString: @"http://foo/../qux"]]) objc_autoreleasePoolPop(pool); } @end |
Modified tests/OFValueTests.m from [55c7d2a02d] to [9e3cfa0f76].
︙ | ︙ | |||
22 23 24 25 26 27 28 | #import "TestsAppDelegate.h" static OFString *module = @"OFValue"; @implementation TestsAppDelegate (OFValueTests) - (void)valueTests { | | | 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 | #import "TestsAppDelegate.h" static OFString *module = @"OFValue"; @implementation TestsAppDelegate (OFValueTests) - (void)valueTests { void *pool = objc_autoreleasePoolPush(); of_range_t range = of_range(1, 64), range2; of_point_t point = of_point(1.5, 3), point2; of_dimension_t dimension = of_dimension(4.5, 5), dimension2; of_rectangle_t rectangle = of_rectangle(1.5, 3, 4.5, 6), rectangle2; OFValue *value; void *pointer = &value; |
︙ | ︙ | |||
165 166 167 168 169 170 171 | isEqual: [OFValue valueWithBytes: "a" objCType: @encode(unsigned char)]] && ![[OFValue valueWithBytes: "a" objCType: @encode(char)] isEqual: [OFValue valueWithBytes: "b" objCType: @encode(char)]]) | | | 165 166 167 168 169 170 171 172 173 174 | isEqual: [OFValue valueWithBytes: "a" objCType: @encode(unsigned char)]] && ![[OFValue valueWithBytes: "a" objCType: @encode(char)] isEqual: [OFValue valueWithBytes: "b" objCType: @encode(char)]]) objc_autoreleasePoolPop(pool); } @end |
Modified tests/OFWindowsRegistryKeyTests.m from [ffa2fecd61] to [ba51942ca7].
︙ | ︙ | |||
20 21 22 23 24 25 26 | #import "TestsAppDelegate.h" static OFString *module = @"OFWindowsRegistryKey"; @implementation TestsAppDelegate (OFWindowsRegistryKeyTests) - (void)windowsRegistryKeyTests { | | | 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 | #import "TestsAppDelegate.h" static OFString *module = @"OFWindowsRegistryKey"; @implementation TestsAppDelegate (OFWindowsRegistryKeyTests) - (void)windowsRegistryKeyTests { void *pool = objc_autoreleasePoolPush(); OFData *data = [OFData dataWithItems: "abcdef" count: 6]; OFWindowsRegistryKey *softwareKey, *ObjFWKey; DWORD type; OFString *string; TEST(@"+[OFWindowsRegistryKey classesRootKey]", |
︙ | ︙ | |||
91 92 93 94 95 96 97 | [string hasSuffix: @";foo"]) TEST(@"-[deleteValue:]", R([ObjFWKey deleteValue: @"data"])) TEST(@"-[deleteSubkeyAtPath:]", R([softwareKey deleteSubkeyAtPath: @"ObjFW"])) | | | 91 92 93 94 95 96 97 98 99 100 | [string hasSuffix: @";foo"]) TEST(@"-[deleteValue:]", R([ObjFWKey deleteValue: @"data"])) TEST(@"-[deleteSubkeyAtPath:]", R([softwareKey deleteSubkeyAtPath: @"ObjFW"])) objc_autoreleasePoolPop(pool); } @end |
Modified tests/OFXMLElementBuilderTests.m from [959dacaa15] to [2bc3c1f12c].
︙ | ︙ | |||
36 37 38 39 40 41 42 | { OF_ENSURE(i == 1); nodes[i++] = [node retain]; } - (void)XMLElementBuilderTests { | | | | 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 | { OF_ENSURE(i == 1); nodes[i++] = [node retain]; } - (void)XMLElementBuilderTests { void *pool = objc_autoreleasePoolPush(); OFXMLParser *p = [OFXMLParser parser]; OFXMLElementBuilder *builder = [OFXMLElementBuilder elementBuilder]; OFString *str = @"<foo>bar<![CDATA[f<oo]]>baz<qux/>" " <qux xmlns:qux='urn:qux'><?asd?><qux:bar/><x qux:y='z'/></qux>" "</foo>"; p.delegate = builder; builder.delegate = self; TEST(@"Building elements from parsed XML", R([p parseString: str]) && nodes[0] != nil && [nodes[0].XMLString isEqual: str] && R([p parseString: @"<!--foo-->"]) && nodes[1] != nil && [nodes[1].XMLString isEqual: @"<!--foo-->"] && i == 2) [nodes[0] release]; [nodes[1] release]; objc_autoreleasePoolPop(pool); } @end |
Modified tests/OFXMLNodeTests.m from [dfc573ade9] to [4fa85e4e25].
︙ | ︙ | |||
20 21 22 23 24 25 26 | #import "TestsAppDelegate.h" static OFString *module = @"OFXMLNode"; @implementation TestsAppDelegate (OFXMLNodeTests) - (void)XMLNodeTests { | | | 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 | #import "TestsAppDelegate.h" static OFString *module = @"OFXMLNode"; @implementation TestsAppDelegate (OFXMLNodeTests) - (void)XMLNodeTests { void *pool = objc_autoreleasePoolPush(); id nodes[4]; OFArray *a; TEST(@"+[elementWithName:]", (nodes[0] = [OFXMLElement elementWithName: @"foo"]) && [[nodes[0] XMLString] isEqual: @"<foo/>"]) |
︙ | ︙ | |||
134 135 136 137 138 139 140 | [OFXMLElement elementWithXMLString: @"<x><y></y></x>"]]) TEST(@"-[XMLStringWithIndentation:]", [[[OFXMLElement elementWithXMLString: @"<x><y><z>a\nb</z>" @"<!-- foo --></y></x>"] XMLStringWithIndentation: 2] isEqual: @"<x>\n <y>\n <z>a\nb</z>\n <!-- foo -->\n </y>\n</x>"]) | | | 134 135 136 137 138 139 140 141 142 143 | [OFXMLElement elementWithXMLString: @"<x><y></y></x>"]]) TEST(@"-[XMLStringWithIndentation:]", [[[OFXMLElement elementWithXMLString: @"<x><y><z>a\nb</z>" @"<!-- foo --></y></x>"] XMLStringWithIndentation: 2] isEqual: @"<x>\n <y>\n <z>a\nb</z>\n <!-- foo -->\n </y>\n</x>"]) objc_autoreleasePoolPop(pool); } @end |
Modified tests/OFXMLParserTests.m from [e683ca54ff] to [bde20c3f2b].
︙ | ︙ | |||
318 319 320 321 322 323 324 | return @"foobar"; return nil; } - (void)XMLParserTests { | | | 318 319 320 321 322 323 324 325 326 327 328 329 330 331 332 | return @"foobar"; return nil; } - (void)XMLParserTests { void *pool = objc_autoreleasePoolPush(); const char *str = "\xEF\xBB\xBF<?xml version='1.0'?><?p?i?>" "<!DOCTYPE foo><root>\r\r" " <![CDATA[f<]]]oo]]]><bar/>\n" " <foobar xmlns='urn:objfw:test:foobar'>\r\n" " <qux xmlns:foo='urn:objfw:test:foo'>\n" " <foo:bla foo:bla = 'bla' blafoo='foo'>\n" " <blup foo:qux='asd' quxqux='test'/>\n" |
︙ | ︙ | |||
388 389 390 391 392 393 394 | [parser parseString: @"<?xml encoding='UTF-7'?>"]) parser = [OFXMLParser parser]; EXPECT_EXCEPTION(@"Detection of invalid XML processing instructions #3", OFMalformedXMLException, [parser parseString: @"<x><?xml?></x>"]) | | | 388 389 390 391 392 393 394 395 396 397 | [parser parseString: @"<?xml encoding='UTF-7'?>"]) parser = [OFXMLParser parser]; EXPECT_EXCEPTION(@"Detection of invalid XML processing instructions #3", OFMalformedXMLException, [parser parseString: @"<x><?xml?></x>"]) objc_autoreleasePoolPop(pool); } @end |
Modified tests/PBKDF2Tests.m from [7299afd4f0] to [390e84b82b].
︙ | ︙ | |||
22 23 24 25 26 27 28 | #import "TestsAppDelegate.h" static OFString *module = @"PBKDF2"; @implementation TestsAppDelegate (PBKDF2Tests) - (void)PBKDF2Tests { | | | 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 | #import "TestsAppDelegate.h" static OFString *module = @"PBKDF2"; @implementation TestsAppDelegate (PBKDF2Tests) - (void)PBKDF2Tests { void *pool = objc_autoreleasePoolPush(); OFHMAC *HMAC = [OFHMAC HMACWithHashClass: [OFSHA1Hash class]]; unsigned char key[25]; /* Test vectors from RFC 6070 */ TEST(@"PBKDF2-SHA1, 1 iteration", R(of_pbkdf2(HMAC, 1, (unsigned char *)"salt", 4, "password", 8, key, |
︙ | ︙ | |||
68 69 70 71 72 73 74 | TEST(@"PBKDF2-SHA1, 4096 iterations, key < 1 block", R(of_pbkdf2(HMAC, 4096, (unsigned char *)"sa\0lt", 5, "pass\0word", 9, key, 16)) && memcmp(key, "\x56\xFA\x6A\xA7\x55\x48\x09\x9D\xCC\x37\xD7\xF0\x34" "\x25\xE0\xC3", 16) == 0) | | | 68 69 70 71 72 73 74 75 76 77 | TEST(@"PBKDF2-SHA1, 4096 iterations, key < 1 block", R(of_pbkdf2(HMAC, 4096, (unsigned char *)"sa\0lt", 5, "pass\0word", 9, key, 16)) && memcmp(key, "\x56\xFA\x6A\xA7\x55\x48\x09\x9D\xCC\x37\xD7\xF0\x34" "\x25\xE0\xC3", 16) == 0) objc_autoreleasePoolPop(pool); } @end |
Modified tests/RuntimeTests.m from [b3c5975985] to [bde874f5eb].
︙ | ︙ | |||
60 61 62 63 64 65 66 | return [self superTest]; } @end @implementation TestsAppDelegate (RuntimeTests) - (void)runtimeTests { | | | | 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 | return [self superTest]; } @end @implementation TestsAppDelegate (RuntimeTests) - (void)runtimeTests { void *pool = objc_autoreleasePoolPush(); RuntimeTest *rt = [[[RuntimeTest alloc] init] autorelease]; OFString *t, *foo; EXPECT_EXCEPTION(@"Calling a non-existent method via super", OFNotImplementedException, [rt superTest]) TEST(@"Calling a method via a super with self == nil", [rt nilSuperTest] == nil) t = [OFMutableString stringWithString: @"foo"]; foo = @"foo"; [rt setFoo: t]; TEST(@"copy, nonatomic properties", [rt.foo isEqual: foo] && rt.foo != foo && rt.foo.retainCount == 1) rt.bar = t; TEST(@"retain, atomic properties", rt.bar == t && t.retainCount == 3) objc_autoreleasePoolPop(pool); } @end |
Modified tests/ScryptTests.m from [30690c0cdc] to [f9dfdefc9d].
︙ | ︙ | |||
131 132 133 134 135 136 137 | 0xA7, 0x7A, 0x41, 0xA4 }; #endif @implementation TestsAppDelegate (ScryptTests) - (void)scryptTests { | | | 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 | 0xA7, 0x7A, 0x41, 0xA4 }; #endif @implementation TestsAppDelegate (ScryptTests) - (void)scryptTests { void *pool = objc_autoreleasePoolPush(); uint32_t salsa20Buffer[16]; uint32_t blockMixBuffer[32]; uint32_t ROMixBuffer[32], ROMixTmp[17 * 32]; unsigned char output[64]; TEST(@"Salsa20/8 Core", R(memcpy(salsa20Buffer, salsa20Input, 64)) && |
︙ | ︙ | |||
172 173 174 175 176 177 178 | #if 0 TEST(@"scrypt test vector #4", R(of_scrypt(8, 1048576, 1, (unsigned char *)"SodiumChloride", 14, "pleaseletmein", 13, output, 64)) && memcmp(output, testVector4, 64) == 0) #endif | | | 172 173 174 175 176 177 178 179 180 181 | #if 0 TEST(@"scrypt test vector #4", R(of_scrypt(8, 1048576, 1, (unsigned char *)"SodiumChloride", 14, "pleaseletmein", 13, output, 64)) && memcmp(output, testVector4, 64) == 0) #endif objc_autoreleasePoolPop(pool); } @end |
Modified tests/SocketTests.m from [b227fbab77] to [7f86bc0a37].
︙ | ︙ | |||
55 56 57 58 59 60 61 | a.sockaddr.in6.sin6_addr.s6_addr[15] = a7 & 0xFF; static OFString *module = @"Socket"; @implementation TestsAppDelegate (SocketTests) - (void)socketTests { | | | 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 | a.sockaddr.in6.sin6_addr.s6_addr[15] = a7 & 0xFF; static OFString *module = @"Socket"; @implementation TestsAppDelegate (SocketTests) - (void)socketTests { void *pool = objc_autoreleasePoolPush(); of_socket_address_t addr; uint16_t port; TEST(@"Parsing an IPv4", R(addr = of_socket_address_parse_ip(@"127.0.0.1", 1234)) && OF_BSWAP32_IF_LE(addr.sockaddr.in.sin_addr.s_addr) == 0x7F000001 && OF_BSWAP16_IF_LE(addr.sockaddr.in.sin_port) == 1234) |
︙ | ︙ | |||
217 218 219 220 221 222 223 | SET_V6(addr, 0, 0, 0x5566, 0x7788, 0x99AA, 0xBBCC, 0, 0) TEST(@"Converting an IPv6 to a string #10", [of_socket_address_ip_string(&addr, &port) isEqual: @"::5566:7788:99aa:bbcc:0:0"] && port == 1234) | | | 217 218 219 220 221 222 223 224 225 226 | SET_V6(addr, 0, 0, 0x5566, 0x7788, 0x99AA, 0xBBCC, 0, 0) TEST(@"Converting an IPv6 to a string #10", [of_socket_address_ip_string(&addr, &port) isEqual: @"::5566:7788:99aa:bbcc:0:0"] && port == 1234) objc_autoreleasePoolPop(pool); } @end |
Modified tests/TestsAppDelegate.m from [817dd9ac34] to [69d46f9e91].
︙ | ︙ | |||
258 259 260 261 262 263 264 | # error No output method! #endif } - (void)outputTesting: (OFString *)test inModule: (OFString *)module { | | | | | | | | 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 306 307 308 | # error No output method! #endif } - (void)outputTesting: (OFString *)test inModule: (OFString *)module { void *pool = objc_autoreleasePoolPush(); #ifndef STDOUT_SIMPLE [self outputString: [OFString stringWithFormat: @"[%@] %@: testing...", module, test] inColor: YELLOW]; #else [self outputString: [OFString stringWithFormat: @"[%@] %@: ", module, test] inColor: YELLOW]; #endif objc_autoreleasePoolPop(pool); } - (void)outputSuccess: (OFString *)test inModule: (OFString *)module { #ifndef STDOUT_SIMPLE void *pool = objc_autoreleasePoolPush(); [self outputString: [OFString stringWithFormat: @"[%@] %@: ok\n", module, test] inColor: GREEN]; objc_autoreleasePoolPop(pool); #else [self outputString: @"ok\n" inColor: GREEN]; #endif } - (void)outputFailure: (OFString *)test inModule: (OFString *)module { #ifndef STDOUT_SIMPLE void *pool = objc_autoreleasePoolPush(); [self outputString: [OFString stringWithFormat: @"[%@] %@: failed\n", module, test] inColor: RED]; objc_autoreleasePoolPop(pool); # ifdef OF_WII [self outputString: @"Press A to continue!\n" inColor: NO_COLOR]; for (;;) { WPAD_ScanPads(); |
︙ | ︙ |