diff options
author | rowanbeentje <rowan@beent.je> | 2010-03-31 23:35:06 +0000 |
---|---|---|
committer | rowanbeentje <rowan@beent.je> | 2010-03-31 23:35:06 +0000 |
commit | 06e417594cd0fcdede2f0713c63a861bc65d7e99 (patch) | |
tree | de21be7bf852ec3a03c9baf2535ce4cebb5d0cdd /Frameworks/MCPKit/MCPFoundationKit | |
parent | 836b96f7e1481938c0267448b940b5d8e202eb09 (diff) | |
download | sequelpro-06e417594cd0fcdede2f0713c63a861bc65d7e99.tar.gz sequelpro-06e417594cd0fcdede2f0713c63a861bc65d7e99.tar.bz2 sequelpro-06e417594cd0fcdede2f0713c63a861bc65d7e99.zip |
- Improve SPSSHTunnel question/password dialogs to no longer eat 100% CPU by switching from NSCondition blocking to NSLock blocking
- Improve behaviour of SSH tunnels with no password in keychain - prompt appropriately
- Set MXPConnection to check the proxy state when attempting to reconnect a dropped connection, extending the timer when an auth UI is up. This prevents a multiple-dialogs misbehaviour (or sometimes deadlock), addressing the last part of http://log.sequelpro.com/view/86 .
Diffstat (limited to 'Frameworks/MCPKit/MCPFoundationKit')
-rw-r--r-- | Frameworks/MCPKit/MCPFoundationKit/MCPConnection.m | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/Frameworks/MCPKit/MCPFoundationKit/MCPConnection.m b/Frameworks/MCPKit/MCPFoundationKit/MCPConnection.m index 7571cd0e..555f87dc 100644 --- a/Frameworks/MCPKit/MCPFoundationKit/MCPConnection.m +++ b/Frameworks/MCPKit/MCPFoundationKit/MCPConnection.m @@ -476,7 +476,7 @@ static BOOL sTruncateLongFieldInLogs = YES; eventLoopStartDate = [NSDate date]; [[NSRunLoop currentRunLoop] runMode:NSModalPanelRunLoopMode beforeDate:[NSDate dateWithTimeIntervalSinceNow:0.25]]; if ([[NSDate date] timeIntervalSinceDate:eventLoopStartDate] < 0.25) { - usleep(250000 - (100000 * [[NSDate date] timeIntervalSinceDate:eventLoopStartDate])); + usleep(250000 - (1000000 * [[NSDate date] timeIntervalSinceDate:eventLoopStartDate])); } } @@ -505,7 +505,10 @@ static BOOL sTruncateLongFieldInLogs = YES; if ([[NSDate date] timeIntervalSinceDate:interfaceInteractionTimer] > 0.25) { proxyStartDate = [proxyStartDate addTimeInterval:([[NSDate date] timeIntervalSinceDate:interfaceInteractionTimer] - 0.25)]; } else { - usleep(250000 - (100000 * [[NSDate date] timeIntervalSinceDate:interfaceInteractionTimer])); + usleep(250000 - (1000000 * [[NSDate date] timeIntervalSinceDate:interfaceInteractionTimer])); + if ([connectionProxy state] == PROXY_STATE_WAITING_FOR_AUTH) { + proxyStartDate = [proxyStartDate addTimeInterval:0.26]; + } } } |