Add comment about waiting time

This commit is contained in:
Sergey Abramchuk 2017-04-15 10:39:54 +03:00
parent 2f10fee86d
commit be46d31c7e

View File

@ -272,6 +272,7 @@ static void socketCallback(CFSocketRef socket, CFSocketCallBackType type, CFData
dispatch_semaphore_signal(sema);
}];
// Wait 10 seconds
dispatch_time_t timeout = dispatch_time(DISPATCH_TIME_NOW, 10 * NSEC_PER_SEC);
if (dispatch_semaphore_wait(sema, timeout) != 0) {
NSLog(@"Failed to establish tunnel in a reasonable time");