diff options
author | rowanbeentje <rowan@beent.je> | 2011-01-04 23:04:07 +0000 |
---|---|---|
committer | rowanbeentje <rowan@beent.je> | 2011-01-04 23:04:07 +0000 |
commit | df7720cd97dcbeeb1ba3a74c2bc2dae2bf4276cd (patch) | |
tree | c674e3f2f2c6d80928718327f8e2137dbb70a92a /Source/SPSSHTunnel.m | |
parent | 12c773ff7f06a240e66a264b23261f0436e56175 (diff) | |
download | sequelpro-df7720cd97dcbeeb1ba3a74c2bc2dae2bf4276cd.tar.gz sequelpro-df7720cd97dcbeeb1ba3a74c2bc2dae2bf4276cd.tar.bz2 sequelpro-df7720cd97dcbeeb1ba3a74c2bc2dae2bf4276cd.zip |
- Fix SSH tunnels for connections with non-Latin characters in their name
- If SSH tunnel password lookups fail, fall back to asking the user for the password
- Don't reset keychain IDs across documents if not set; this fixes problems re-saving .spfs or duplicating chains of tabs
Diffstat (limited to 'Source/SPSSHTunnel.m')
-rw-r--r-- | Source/SPSSHTunnel.m | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/Source/SPSSHTunnel.m b/Source/SPSSHTunnel.m index 76508304..0d4b5993 100644 --- a/Source/SPSSHTunnel.m +++ b/Source/SPSSHTunnel.m @@ -328,8 +328,8 @@ [taskEnvironment setObject:tunnelConnectionVerifyHash forKey:@"SP_CONNECTION_VERIFY_HASH"]; if (passwordInKeychain) { [taskEnvironment setObject:[[NSNumber numberWithInteger:SPSSHPasswordUsesKeychain] stringValue] forKey:@"SP_PASSWORD_METHOD"]; - [taskEnvironment setObject:keychainName forKey:@"SP_KEYCHAIN_ITEM_NAME"]; - [taskEnvironment setObject:keychainAccount forKey:@"SP_KEYCHAIN_ITEM_ACCOUNT"]; + [taskEnvironment setObject:[keychainName stringByAddingPercentEscapesUsingEncoding:NSUTF8StringEncoding] forKey:@"SP_KEYCHAIN_ITEM_NAME"]; + [taskEnvironment setObject:[keychainAccount stringByAddingPercentEscapesUsingEncoding:NSUTF8StringEncoding] forKey:@"SP_KEYCHAIN_ITEM_ACCOUNT"]; } else if (password) { [taskEnvironment setObject:[[NSNumber numberWithInteger:SPSSHPasswordAsksUI] stringValue] forKey:@"SP_PASSWORD_METHOD"]; } else { |