[X2Go-Dev] [RFC] [PATCH] Raise SSH connection timeout to 60 seconds.
Mihai Moldovan
ionic at ionic.de
Sun Feb 26 16:26:57 CET 2012
The default of 10 seconds is pretty low, especially when using
tcp_wrappers with the identd option turned on. Wait for a 60 seconds
timeout.
Signed-off-by: Mihai Moldovan <ionic at ionic.de>
---
sshmasterconnection.cpp | 4 ++++
1 files changed, 4 insertions(+), 0 deletions(-)
diff --git a/sshmasterconnection.cpp b/sshmasterconnection.cpp
index 2626346..9c6626a 100644
--- a/sshmasterconnection.cpp
+++ b/sshmasterconnection.cpp
@@ -137,6 +137,7 @@ void SshMasterConnection::run()
#endif
// int verbosity=SSH_LOG_PROTOCOL;
+ long timeout = 60;
my_ssh_session = ssh_new();
if ( my_ssh_session == NULL )
@@ -153,6 +154,9 @@ void SshMasterConnection::run()
ssh_options_set ( my_ssh_session, SSH_OPTIONS_SSH_DIR,
(mainWnd->getHomeDirectory()+"/ssh").toAscii());
#endif
// ssh_options_set(my_ssh_session, SSH_OPTIONS_LOG_VERBOSITY,
&verbosity);
+
+ ssh_options_set(my_ssh_session, SSH_OPTIONS_TIMEOUT, &timeout);
+
if ( !sshConnect() )
{
QString err=ssh_get_error ( my_ssh_session );
--
1.7.9
-------------- next part --------------
A non-text attachment was scrubbed...
Name: smime.p7s
Type: application/pkcs7-signature
Size: 4369 bytes
Desc: S/MIME Cryptographic Signature
URL: <http://lists.x2go.org/pipermail/x2go-dev/attachments/20120226/d67481ee/attachment.bin>
More information about the x2go-dev
mailing list