merge IOSAD-124
authorbuff <andreas@pep-project.org>
Mon, 22 Jul 2019 15:27:22 +0200
changeset 1078bcdc0be31b68
parent 1068 0d033e967ac7
parent 1077 cbad0128c701
child 1079 e294a7f1541f
child 1098 7e325f306580
merge IOSAD-124
pEpObjCAdapter/PEPLock.h
pEpObjCAdapter/PEPLock.m
     1.1 --- a/pEpObjCAdapter.xcodeproj/project.pbxproj	Tue Jul 16 14:55:48 2019 +0200
     1.2 +++ b/pEpObjCAdapter.xcodeproj/project.pbxproj	Mon Jul 22 15:27:22 2019 +0200
     1.3 @@ -52,7 +52,6 @@
     1.4  		435F5179222046C2006EB11F /* NSNumber+PEPRating.m in Sources */ = {isa = PBXBuildFile; fileRef = 435665CB2080A6CB00EC5B10 /* NSNumber+PEPRating.m */; };
     1.5  		435F517A222046C2006EB11F /* NSObject+Extension.m in Sources */ = {isa = PBXBuildFile; fileRef = 439393E5208F375800EB1DBD /* NSObject+Extension.m */; };
     1.6  		435F517B222046C2006EB11F /* NSMutableDictionary+PEP.m in Sources */ = {isa = PBXBuildFile; fileRef = 439393F7208F5B5E00EB1DBD /* NSMutableDictionary+PEP.m */; };
     1.7 -		435F517C222046C2006EB11F /* PEPLock.m in Sources */ = {isa = PBXBuildFile; fileRef = 43F73BD32165F6EC00AB4524 /* PEPLock.m */; };
     1.8  		435F517D222046C2006EB11F /* PEPSync.m in Sources */ = {isa = PBXBuildFile; fileRef = 43F73BE92166248E00AB4524 /* PEPSync.m */; };
     1.9  		435F519022204A67006EB11F /* PEPSessionProtocol.h in Headers */ = {isa = PBXBuildFile; fileRef = 435F518F22204A67006EB11F /* PEPSessionProtocol.h */; settings = {ATTRIBUTES = (Public, ); }; };
    1.10  		4360AA0E2227F22900E62E5A /* PEPObjCAdapter.h in Headers */ = {isa = PBXBuildFile; fileRef = 43209B2F1ECC2ACD007E7E2E /* PEPObjCAdapter.h */; settings = {ATTRIBUTES = (Public, ); }; };
    1.11 @@ -205,8 +204,6 @@
    1.12  		43E3985D221D7E56008E7983 /* PEPObjCAdapterFramework.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = PEPObjCAdapterFramework.h; sourceTree = "<group>"; };
    1.13  		43E3985E221D7E56008E7983 /* Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = "<group>"; };
    1.14  		43E3986A221D7EDD008E7983 /* libiconv.2.tbd */ = {isa = PBXFileReference; lastKnownFileType = "sourcecode.text-based-dylib-definition"; name = libiconv.2.tbd; path = usr/lib/libiconv.2.tbd; sourceTree = SDKROOT; };
    1.15 -		43F73BD22165F6EC00AB4524 /* PEPLock.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = PEPLock.h; sourceTree = "<group>"; };
    1.16 -		43F73BD32165F6EC00AB4524 /* PEPLock.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = PEPLock.m; sourceTree = "<group>"; };
    1.17  		43F73BE92166248E00AB4524 /* PEPSync.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = PEPSync.m; sourceTree = "<group>"; };
    1.18  		43FF2ECC2226AE7E000D9567 /* PEPEngineTypes.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; name = PEPEngineTypes.h; path = pEpObjCAdapterFramework/PEPEngineTypes.h; sourceTree = SOURCE_ROOT; };
    1.19  		640F79211C9B517C00DBEC4E /* 5CB2C182_sec.asc */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text; path = 5CB2C182_sec.asc; sourceTree = "<group>"; };
    1.20 @@ -348,8 +345,6 @@
    1.21  				439393E5208F375800EB1DBD /* NSObject+Extension.m */,
    1.22  				439393F6208F5B5E00EB1DBD /* NSMutableDictionary+PEP.h */,
    1.23  				439393F7208F5B5E00EB1DBD /* NSMutableDictionary+PEP.m */,
    1.24 -				43F73BD22165F6EC00AB4524 /* PEPLock.h */,
    1.25 -				43F73BD32165F6EC00AB4524 /* PEPLock.m */,
    1.26  				43F73BE92166248E00AB4524 /* PEPSync.m */,
    1.27  				430CD9BF2292B1EA00AAC37F /* PEPSync_Internal.h */,
    1.28  			);
    1.29 @@ -627,7 +622,6 @@
    1.30  				435F5179222046C2006EB11F /* NSNumber+PEPRating.m in Sources */,
    1.31  				435F516B222046C2006EB11F /* PEPMessageUtil.m in Sources */,
    1.32  				435F5171222046C2006EB11F /* PEPCopyableThread.m in Sources */,
    1.33 -				435F517C222046C2006EB11F /* PEPLock.m in Sources */,
    1.34  				435F5175222046C2006EB11F /* PEPMessage.m in Sources */,
    1.35  				435F5174222046C2006EB11F /* PEPIdentity.m in Sources */,
    1.36  				435F517A222046C2006EB11F /* NSObject+Extension.m in Sources */,
     2.1 --- a/pEpObjCAdapter/PEPInternalSession.m	Tue Jul 16 14:55:48 2019 +0200
     2.2 +++ b/pEpObjCAdapter/PEPInternalSession.m	Mon Jul 22 15:27:22 2019 +0200
     2.3 @@ -24,7 +24,6 @@
     2.4  #import "PEPAutoPointer.h"
     2.5  #import "NSNumber+PEPRating.h"
     2.6  #import "NSMutableDictionary+PEP.h"
     2.7 -#import "PEPLock.h"
     2.8  #import "PEPSync_Internal.h"
     2.9  
    2.10  #import "key_reset.h"
    2.11 @@ -49,7 +48,7 @@
    2.12  
    2.13  - (void)dealloc
    2.14  {
    2.15 -    [PEPSync releaseSession:_session];
    2.16 +    release(_session);
    2.17  }
    2.18  
    2.19  #pragma mark - CONFIG
    2.20 @@ -61,16 +60,6 @@
    2.21  
    2.22  #pragma mark - INTERNAL
    2.23  
    2.24 -- (void)lockWrite
    2.25 -{
    2.26 -    [PEPLock lockWrite];
    2.27 -}
    2.28 -
    2.29 -- (void)unlockWrite
    2.30 -{
    2.31 -    [PEPLock unlockWrite];
    2.32 -}
    2.33 -
    2.34  + (void)setupTrustWordsDB
    2.35  {
    2.36      static dispatch_once_t once;
    2.37 @@ -133,14 +122,12 @@
    2.38  
    2.39      PEPRating internalRating = PEPRatingUndefined;
    2.40  
    2.41 -    [self lockWrite];
    2.42      PEPStatus theStatus = (PEPStatus) decrypt_message(_session,
    2.43                                                        _src,
    2.44                                                        &_dst,
    2.45                                                        &theKeys,
    2.46                                                        (PEP_rating *) &internalRating,
    2.47                                                        (PEP_decrypt_flags *) &theFlags);
    2.48 -    [self unlockWrite];
    2.49  
    2.50      if (status) {
    2.51          *status = theStatus;
    2.52 @@ -217,13 +204,11 @@
    2.53          theKeys = PEP_arrayToStringlist(xKeyList);
    2.54      }
    2.55  
    2.56 -    [self lockWrite];
    2.57      PEPStatus theStatus = (PEPStatus) re_evaluate_message_rating(_session,
    2.58                                                                   _src,
    2.59                                                                   theKeys,
    2.60                                                                   (PEP_rating) *rating,
    2.61                                                                   (PEP_rating *) rating);
    2.62 -    [self unlockWrite];
    2.63  
    2.64      free_message(_src);
    2.65      free_stringlist(theKeys);
    2.66 @@ -315,7 +300,7 @@
    2.67  }
    2.68  
    2.69  - (PEPMessage * _Nullable)encryptMessage:(PEPMessage * _Nonnull)message
    2.70 -                                   extraKeys:(PEPStringList * _Nullable)extraKeys
    2.71 +                               extraKeys:(PEPStringList * _Nullable)extraKeys
    2.72                                 encFormat:(PEPEncFormat)encFormat
    2.73                                    status:(PEPStatus * _Nullable)status
    2.74                                     error:(NSError * _Nullable * _Nullable)error
    2.75 @@ -335,7 +320,7 @@
    2.76  }
    2.77  
    2.78  - (PEPMessage * _Nullable)encryptMessage:(PEPMessage * _Nonnull)message
    2.79 -                                   extraKeys:(PEPStringList * _Nullable)extraKeys
    2.80 +                               extraKeys:(PEPStringList * _Nullable)extraKeys
    2.81                                    status:(PEPStatus * _Nullable)status
    2.82                                     error:(NSError * _Nullable * _Nullable)error
    2.83  {
    2.84 @@ -361,7 +346,6 @@
    2.85  
    2.86      stringlist_t *keysStringList = PEP_arrayToStringlist(extraKeys);
    2.87  
    2.88 -    [self lockWrite];
    2.89      PEPStatus theStatus = (PEPStatus) encrypt_message_for_self(_session,
    2.90                                                                 ident,
    2.91                                                                 _src,
    2.92 @@ -369,7 +353,6 @@
    2.93                                                                 &_dst,
    2.94                                                                 PEP_enc_PGP_MIME,
    2.95                                                                 flags);
    2.96 -    [self unlockWrite];
    2.97  
    2.98      free_stringlist(keysStringList);
    2.99  
   2.100 @@ -430,12 +413,10 @@
   2.101      message *src = PEP_messageDictToStruct([self removeEmptyRecipients:messageDict]);
   2.102      message *dst = NULL;
   2.103  
   2.104 -    [self lockWrite];
   2.105      PEPStatus theStatus = (PEPStatus)
   2.106      encrypt_message_and_add_priv_key(_session, src, &dst,
   2.107                                       [[toFpr precomposedStringWithCanonicalMapping] UTF8String],
   2.108                                       (PEP_enc_format) encFormat, flags);
   2.109 -    [self unlockWrite];
   2.110  
   2.111      if (status) {
   2.112          *status = theStatus;
   2.113 @@ -485,11 +466,9 @@
   2.114      message *_msg = PEP_messageToStruct(theMessage);
   2.115      PEPRating rating = PEPRatingUndefined;
   2.116  
   2.117 -    [self lockWrite];
   2.118      PEPStatus status = (PEPStatus) outgoing_message_rating(_session,
   2.119                                                             _msg,
   2.120                                                             (PEP_rating *) &rating);
   2.121 -    [self unlockWrite];
   2.122  
   2.123      free_message(_msg);
   2.124  
   2.125 @@ -524,9 +503,7 @@
   2.126      pEp_identity *ident = PEP_identityToStruct(identity);
   2.127      PEPRating rating = PEPRatingUndefined;
   2.128  
   2.129 -    [self lockWrite];
   2.130      PEPStatus status = (PEPStatus) identity_rating(_session, ident, (PEP_rating *) &rating);
   2.131 -    [self unlockWrite];
   2.132  
   2.133      free_identity(ident);
   2.134  
   2.135 @@ -577,9 +554,7 @@
   2.136  {
   2.137      pEp_identity *ident = PEP_identityToStruct(identity);
   2.138  
   2.139 -    [self lockWrite];
   2.140      PEPStatus status = (PEPStatus) myself(_session, ident);
   2.141 -    [self unlockWrite];
   2.142  
   2.143      if ([NSError setError:error fromPEPStatus:status]) {
   2.144          free_identity(ident);
   2.145 @@ -600,10 +575,8 @@
   2.146      } else {
   2.147          pEp_identity *ident = PEP_identityToStruct(identity);
   2.148  
   2.149 -        [self lockWrite];
   2.150          PEPStatus status = (PEPStatus) update_identity(_session, ident);
   2.151 -        [self unlockWrite];
   2.152 -
   2.153 +        
   2.154          if ([NSError setError:error fromPEPStatus:status]) {
   2.155              free_identity(ident);
   2.156              return NO;
   2.157 @@ -622,9 +595,7 @@
   2.158  {
   2.159      pEp_identity *ident = PEP_identityToStruct(identity);
   2.160  
   2.161 -    [self lockWrite];
   2.162      PEPStatus status = (PEPStatus) trust_personal_key(_session, ident);
   2.163 -    [self unlockWrite];
   2.164  
   2.165      if ([NSError setError:error fromPEPStatus:status]) {
   2.166          free_identity(ident);
   2.167 @@ -641,9 +612,7 @@
   2.168  {
   2.169      pEp_identity *ident = PEP_identityToStruct(identity);
   2.170  
   2.171 -    [self lockWrite];
   2.172      PEPStatus status = (PEPStatus) key_mistrusted(_session, ident);
   2.173 -    [self unlockWrite];
   2.174  
   2.175      if ([NSError setError:error fromPEPStatus:status]) {
   2.176          free_identity(ident);
   2.177 @@ -662,9 +631,7 @@
   2.178  {
   2.179      pEp_identity *ident = PEP_identityToStruct(identity);
   2.180  
   2.181 -    [self lockWrite];
   2.182      PEPStatus status = (PEPStatus) key_reset_trust(_session, ident);
   2.183 -    [self unlockWrite];
   2.184  
   2.185      if ([NSError setError:error fromPEPStatus:status]) {
   2.186          free_identity(ident);
   2.187 @@ -683,11 +650,9 @@
   2.188  {
   2.189      identity_list *identList = NULL;
   2.190  
   2.191 -    [self lockWrite];
   2.192      PEPStatus status = (PEPStatus) import_key(_session,
   2.193 -                                   [[keydata precomposedStringWithCanonicalMapping] UTF8String],
   2.194 -                                   [keydata length], &identList);
   2.195 -    [self unlockWrite];
   2.196 +                                              [[keydata precomposedStringWithCanonicalMapping] UTF8String],
   2.197 +                                              [keydata length], &identList);
   2.198  
   2.199      if ([NSError setError:error fromPEPStatus:status]) {
   2.200          free(identList);
   2.201 @@ -706,7 +671,6 @@
   2.202           comment:(NSString * _Nullable)comment
   2.203             error:(NSError * _Nullable * _Nullable)error
   2.204  {
   2.205 -    [self lockWrite];
   2.206      PEPStatus status = (PEPStatus) log_event(_session,
   2.207                                               [[title precomposedStringWithCanonicalMapping]
   2.208                                                UTF8String],
   2.209 @@ -716,7 +680,6 @@
   2.210                                                UTF8String],
   2.211                                               [[comment precomposedStringWithCanonicalMapping]
   2.212                                                UTF8String]);
   2.213 -    [self unlockWrite];
   2.214  
   2.215      if ([NSError setError:error fromPEPStatus:status]) {
   2.216          return NO;
   2.217 @@ -755,12 +718,10 @@
   2.218      PEPAutoPointer *trustwords = [PEPAutoPointer new];
   2.219      size_t sizeWritten = 0;
   2.220  
   2.221 -    [self lockWrite];
   2.222      status = (PEPStatus) get_trustwords(_session, ident1, ident2,
   2.223                                          [[language precomposedStringWithCanonicalMapping]
   2.224                                           UTF8String],
   2.225                                          trustwords.charPointerPointer, &sizeWritten, full);
   2.226 -    [self unlockWrite];
   2.227  
   2.228      free_identity(ident1);
   2.229      free_identity(ident2);
   2.230 @@ -776,9 +737,9 @@
   2.231  
   2.232  - (NSString * _Nullable)getTrustwordsFpr1:(NSString * _Nonnull)fpr1
   2.233                                       fpr2:(NSString * _Nonnull)fpr2
   2.234 -                                      language:(NSString * _Nullable)language
   2.235 -                                          full:(BOOL)full
   2.236 -                                         error:(NSError * _Nullable * _Nullable)error
   2.237 +                                 language:(NSString * _Nullable)language
   2.238 +                                     full:(BOOL)full
   2.239 +                                    error:(NSError * _Nullable * _Nullable)error
   2.240  {
   2.241      const char *_fpr1 = [fpr1 UTF8String]; // fprs are NFC normalized anyway
   2.242      const char *_fpr2 = [fpr2 UTF8String];
   2.243 @@ -787,13 +748,11 @@
   2.244      
   2.245      PEPAutoPointer *trustwords = [PEPAutoPointer new];
   2.246      size_t sizeWritten = 0;
   2.247 -    
   2.248 -    [self lockWrite];
   2.249 +
   2.250      status = (PEPStatus) get_trustwords_for_fprs(_session, _fpr1, _fpr2,
   2.251 -                                        [[language precomposedStringWithCanonicalMapping]
   2.252 -                                         UTF8String],
   2.253 -                                        trustwords.charPointerPointer, &sizeWritten, full);
   2.254 -    [self unlockWrite];
   2.255 +                                                 [[language precomposedStringWithCanonicalMapping]
   2.256 +                                                  UTF8String],
   2.257 +                                                 trustwords.charPointerPointer, &sizeWritten, full);
   2.258      
   2.259      NSString *result = nil;
   2.260      
     3.1 --- a/pEpObjCAdapter/PEPLock.h	Tue Jul 16 14:55:48 2019 +0200
     3.2 +++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
     3.3 @@ -1,26 +0,0 @@
     3.4 -//
     3.5 -//  PEPLock.h
     3.6 -//  pEpObjCAdapter
     3.7 -//
     3.8 -//  Created by Dirk Zimmermann on 04.10.18.
     3.9 -//  Copyright © 2018 p≡p. All rights reserved.
    3.10 -//
    3.11 -
    3.12 -#import <Foundation/Foundation.h>
    3.13 -
    3.14 -/**
    3.15 - Provides global locking to all (write) use of pEp sessions.
    3.16 - */
    3.17 -@interface PEPLock : NSObject
    3.18 -
    3.19 -/**
    3.20 - Locks for (potential) sqlite writes.
    3.21 - */
    3.22 -+ (void)lockWrite;
    3.23 -
    3.24 -/**
    3.25 - Unlocks (potential) sqlite writes.
    3.26 - */
    3.27 -+ (void)unlockWrite;
    3.28 -
    3.29 -@end
     4.1 --- a/pEpObjCAdapter/PEPLock.m	Tue Jul 16 14:55:48 2019 +0200
     4.2 +++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
     4.3 @@ -1,30 +0,0 @@
     4.4 -//
     4.5 -//  PEPLock.m
     4.6 -//  pEpObjCAdapter
     4.7 -//
     4.8 -//  Created by Dirk Zimmermann on 04.10.18.
     4.9 -//  Copyright © 2018 p≡p. All rights reserved.
    4.10 -//
    4.11 -
    4.12 -#import "PEPLock.h"
    4.13 -
    4.14 -static NSLock *s_writeLock;
    4.15 -
    4.16 -@implementation PEPLock
    4.17 -
    4.18 -+ (void)initialize
    4.19 -{
    4.20 -    s_writeLock = [[NSLock alloc] init];
    4.21 -}
    4.22 -
    4.23 -+ (void)lockWrite
    4.24 -{
    4.25 -    [s_writeLock lock];
    4.26 -}
    4.27 -
    4.28 -+ (void)unlockWrite
    4.29 -{
    4.30 -    [s_writeLock unlock];
    4.31 -}
    4.32 -
    4.33 -@end
     5.1 --- a/pEpObjCAdapter/PEPObjCAdapter.m	Tue Jul 16 14:55:48 2019 +0200
     5.2 +++ b/pEpObjCAdapter/PEPObjCAdapter.m	Mon Jul 22 15:27:22 2019 +0200
     5.3 @@ -12,7 +12,6 @@
     5.4  #import "PEPObjCAdapter+Internal.h"
     5.5  #import "PEPMessageUtil.h"
     5.6  #import "NSError+PEP.h"
     5.7 -#import "PEPLock.h"
     5.8  
     5.9  #import "keymanagement.h"
    5.10  #import "mime.h"
     6.1 --- a/pEpObjCAdapter/PEPSessionProvider.m	Tue Jul 16 14:55:48 2019 +0200
     6.2 +++ b/pEpObjCAdapter/PEPSessionProvider.m	Mon Jul 22 15:27:22 2019 +0200
     6.3 @@ -38,7 +38,7 @@
     6.4      [[self sessionForThreadLock] lock];
     6.5      NSMutableDictionary<PEPCopyableThread*,PEPInternalSession*> *dict = [self sessionForThreadDict];
     6.6      PEPCopyableThread *currentThread = [[PEPCopyableThread alloc] initWithThread:[NSThread currentThread]];
     6.7 -    PEPInternalSession * __strong newOrExistingSession = dict[currentThread];
     6.8 +    PEPInternalSession * __strong newOrExistingSession = dict[currentThread]; //???: BUFF: Why would this be weak?
     6.9      if (!newOrExistingSession) {
    6.10          newOrExistingSession = [PEPInternalSession new];
    6.11          dict[currentThread] = newOrExistingSession;
     7.1 --- a/pEpObjCAdapter/PEPSync.m	Tue Jul 16 14:55:48 2019 +0200
     7.2 +++ b/pEpObjCAdapter/PEPSync.m	Mon Jul 22 15:27:22 2019 +0200
     7.3 @@ -17,7 +17,6 @@
     7.4  #import "PEPMessageUtil.h"
     7.5  #import "PEPMessage.h"
     7.6  #import "PEPQueue.h"
     7.7 -#import "PEPLock.h"
     7.8  #import "PEPObjCAdapter.h"
     7.9  #import "NSError+PEP+Internal.h"
    7.10  #import "PEPSessionProvider.h"
    7.11 @@ -126,11 +125,9 @@
    7.12  {
    7.13      PEP_SESSION session = NULL;
    7.14  
    7.15 -    [PEPLock lockWrite];
    7.16      PEP_STATUS status = init(&session,
    7.17                               [PEPSync messageToSendCallback],
    7.18                               [PEPSync injectSyncCallback]);
    7.19 -    [PEPLock unlockWrite];
    7.20  
    7.21      if (status != PEP_STATUS_OK) {
    7.22          if (error) {
    7.23 @@ -142,13 +139,6 @@
    7.24      return session;
    7.25  }
    7.26  
    7.27 -+ (void)releaseSession:(PEP_SESSION)session
    7.28 -{
    7.29 -    [PEPLock lockWrite];
    7.30 -    release(session);
    7.31 -    [PEPLock unlockWrite];
    7.32 -}
    7.33 -
    7.34  - (instancetype)initWithSendMessageDelegate:(id<PEPSendMessageDelegate>
    7.35                                               _Nullable)sendMessageDelegate
    7.36                      notifyHandshakeDelegate:(id<PEPNotifyHandshakeDelegate>
    7.37 @@ -166,9 +156,7 @@
    7.38  
    7.39  - (void)startup
    7.40  {
    7.41 -    // assure the main session exists
    7.42 -    PEPInternalSession *session = [PEPSessionProvider session];
    7.43 -    session = nil;
    7.44 +    [self assureMainSessionExists];
    7.45  
    7.46      self.conditionLockForJoiningSyncThread = [[NSConditionLock alloc] initWithCondition:NO];
    7.47      NSThread *theSyncThread = [[NSThread alloc] initWithTarget:self
    7.48 @@ -196,6 +184,11 @@
    7.49      return s_pEpSync;
    7.50  }
    7.51  
    7.52 +- (void)assureMainSessionExists
    7.53 +{
    7.54 +    PEPInternalSession *session __attribute__((unused)) = [PEPSessionProvider session];
    7.55 +}
    7.56 +
    7.57  - (void)syncThreadLoop:(id)object
    7.58  {
    7.59      [self.conditionLockForJoiningSyncThread lock];
     8.1 --- a/pEpObjCAdapter/PEPSync_Internal.h	Tue Jul 16 14:55:48 2019 +0200
     8.2 +++ b/pEpObjCAdapter/PEPSync_Internal.h	Mon Jul 22 15:27:22 2019 +0200
     8.3 @@ -18,11 +18,6 @@
     8.4   */
     8.5  + (PEP_SESSION _Nullable)createSession:(NSError * _Nullable * _Nullable)error;
     8.6  
     8.7 -/**
     8.8 - Releases an engine session that was created by `createSession`.
     8.9 - */
    8.10 -+ (void)releaseSession:(PEP_SESSION _Nullable)session;
    8.11 -
    8.12  @end
    8.13  
    8.14  #endif /* PEPSync_Internal_h */