This is an automated email from the git hooks/post-receive script. x2go pushed a commit to branch feature/libssh-api-upgrade in repository x2goclient.
commit 8063573a5363b1a9819528e75ec357e9d7bcaf09 Author: Mihai Moldovan <io...@ionic.de> Date: Sat Jan 28 17:36:03 2017 +0100 src/sshmasterconnection.cpp: replace deprecated channel_new () function with ssh_channel_new (). Might break on ancient systems, but we don't care. Also, add error handling in case ssh_channel_new () failed... --- debian/changelog | 3 +++ src/sshmasterconnection.cpp | 14 +++++++++++++- 2 files changed, 16 insertions(+), 1 deletion(-) diff --git a/debian/changelog b/debian/changelog index cb8bc9f..da6323a 100644 --- a/debian/changelog +++ b/debian/changelog @@ -573,6 +573,9 @@ x2goclient (4.1.0.0-0x2go1) UNRELEASED; urgency=medium first place. - src/sshmasterconnection.cpp: replace string_free () with its successor ssh_string_free (). Will break on ancient systems, but we don't care. + - src/sshmasterconnection.cpp: replace deprecated channel_new () function + with ssh_channel_new (). Might break on ancient systems, but we don't + care. Also, add error handling in case ssh_channel_new () failed... [ Bernard Cafarelli ] * New upstream version (4.1.0.0): diff --git a/src/sshmasterconnection.cpp b/src/sshmasterconnection.cpp index 57c33fa..360925d 100644 --- a/src/sshmasterconnection.cpp +++ b/src/sshmasterconnection.cpp @@ -1555,7 +1555,19 @@ void SshMasterConnection::channelLoop() #ifdef DEBUG x2goDebug<<"Creating new channel."<<endl; #endif - ssh_channel channel=channel_new ( my_ssh_session ); + ssh_channel channel = ssh_channel_new ( my_ssh_session ); + + if (!channel) { + QString err = ssh_get_error (my_ssh_session); + QString error_msg = tr ("ssh_channel_new failed"); + emit ioErr (channelConnections[i].creator, error_msg + ".", err); + +#ifdef DEBUG + x2goDebug << errorMsg << ": " << err << endl; +#endif + + continue; + } #ifdef DEBUG x2goDebug<<"New channel:"<<channel<<endl; #endif -- Alioth's /srv/git/code.x2go.org/x2goclient.git//..//_hooks_/post-receive-email on /srv/git/code.x2go.org/x2goclient.git _______________________________________________ x2go-commits mailing list x2go-commits@lists.x2go.org http://lists.x2go.org/listinfo/x2go-commits