试图在iOS9上运行我现有的应用程序但在使用时出现故障AFURLSessionManager.
__block NSURLSessionDataTask *task = [self.sessionManager dataTaskWithRequest:request completionHandler:^(NSURLResponse * __unused response, id responseObject, NSError *error) {
if (error) {
} else {
}
}];
[task resume];
Run Code Online (Sandbox Code Playgroud)
我收到以下错误:
Error Domain=NSURLErrorDomain Code=-999 "cancelled.
Run Code Online (Sandbox Code Playgroud)
获取以下日志:
NSURLSession/NSURLConnection HTTP load failed (kCFStreamErrorDomainSSL, -9824
CFNetwork SSLHandshake failed (-9824)
Run Code Online (Sandbox Code Playgroud)
更新: 我已为我的解决方案添加了多个更新: iOS 9上的NSURLSession/NSURLConnection HTTP加载失败
我安装了Xcode 7并尝试在iOS 9下运行我的应用程序.我收到臭名昭着的错误:Connection failed! Error - -1200 An SSL error has occurred and a secure connection to the server cannot be made.
事情是我的服务器支持TLSv1.2并且我正在使用NSURLSession.
那可能是什么问题呢?