Index: src/OFApplication.m ================================================================== --- src/OFApplication.m +++ src/OFApplication.m @@ -605,11 +605,11 @@ - (void)of_activateSandbox: (OFSandbox *)sandbox { # ifdef OF_HAVE_PLEDGE void *pool = objc_autoreleasePoolPush(); OFStringEncoding encoding = [OFLocale encoding]; - OFArray OF_GENERIC(of_sandbox_unveil_path_t) *unveiledPaths; + OFArray OF_GENERIC(OFSandboxUnveilPath) *unveiledPaths; size_t unveiledPathsCount; const char *promises; if (_activeSandbox != nil && sandbox != _activeSandbox) @throw [OFInvalidArgumentException exception]; @@ -617,11 +617,11 @@ unveiledPaths = sandbox.unveiledPaths; unveiledPathsCount = unveiledPaths.count; for (size_t i = sandbox->_unveiledPathsIndex; i < unveiledPathsCount; i++) { - of_sandbox_unveil_path_t unveiledPath = + OFSandboxUnveilPath unveiledPath = [unveiledPaths objectAtIndex: i]; OFString *path = unveiledPath.firstObject; OFString *permissions = unveiledPath.secondObject; if (path == nil || permissions == nil) Index: src/OFSandbox.h ================================================================== --- src/OFSandbox.h +++ src/OFSandbox.h @@ -19,11 +19,11 @@ @class OFArray OF_GENERIC(ObjectType); @class OFMutableArray OF_GENERIC(ObjectType); @class OFPair OF_GENERIC(FirstType, SecondType); -typedef OFPair OF_GENERIC(OFString *, OFString *) *of_sandbox_unveil_path_t; +typedef OFPair OF_GENERIC(OFString *, OFString *) *OFSandboxUnveilPath; @interface OFSandbox: OFObject { unsigned int _allowsStdIO: 1; unsigned int _allowsReadingFiles: 1; @@ -53,11 +53,11 @@ unsigned int _allowsPF: 1; 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; + OFMutableArray OF_GENERIC(OFSandboxUnveilPath) *_unveiledPaths; @public size_t _unveiledPathsIndex; OF_RESERVE_IVARS(OFSandbox, 4) } @@ -93,12 +93,12 @@ @property (nonatomic) bool returnsErrors; #ifdef OF_HAVE_PLEDGE @property (readonly, nonatomic) OFString *pledgeString; #endif @property (readonly, nonatomic) - OFArray OF_GENERIC(of_sandbox_unveil_path_t) *unveiledPaths; + OFArray OF_GENERIC(OFSandboxUnveilPath) *unveiledPaths; + (instancetype)sandbox; - (void)unveilPath: (OFString *)path permissions: (OFString *)permissions; @end OF_ASSUME_NONNULL_END Index: src/OFSandbox.m ================================================================== --- src/OFSandbox.m +++ src/OFSandbox.m @@ -595,10 +595,10 @@ secondObject: permissions]]; objc_autoreleasePoolPop(pool); } -- (OFArray OF_GENERIC(of_sandbox_unveil_path_t) *)unveiledPaths +- (OFArray OF_GENERIC(OFSandboxUnveilPath) *)unveiledPaths { return [[_unveiledPaths copy] autorelease]; } @end