Workaround for Swift2 which apparently fails to retain the completion blocks passed as parameters
This commit is contained in:
@ -759,7 +759,7 @@ static inline NSUInteger _ScanHexNumber(const void* bytes, NSUInteger size) {
|
||||
- (void)processRequest:(GCDWebServerRequest*)request completion:(GCDWebServerCompletionBlock)completion {
|
||||
GWS_LOG_DEBUG(@"Connection on socket %i processing request \"%@ %@\" with %lu bytes body", _socket, _virtualHEAD ? @"HEAD" : _request.method, _request.path, (unsigned long)_bytesRead);
|
||||
@try {
|
||||
_handler.asyncProcessBlock(request, completion);
|
||||
_handler.asyncProcessBlock(request, [completion copy]);
|
||||
}
|
||||
@catch (NSException* exception) {
|
||||
GWS_LOG_EXCEPTION(exception);
|
||||
|
||||
Reference in New Issue
Block a user