[X2Go-Commits] python-x2go.git - brokerclient (branch) updated: 0.2.0.6-4-gbc957c4

X2Go dev team git-admin at x2go.org
Tue Jan 7 16:21:21 CET 2014


The branch, brokerclient has been updated
       via  bc957c408401c7583cb07618c0fc9aee762de3ec (commit)
      from  4d9aad32b35c89acda9c1a6980d4de6d24eb5f02 (commit)

Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.

- Log -----------------------------------------------------------------
-----------------------------------------------------------------------

Summary of changes:
 debian/changelog                 |    2 ++
 x2go/backends/control/_stdout.py |   13 ++++++++-----
 2 files changed, 10 insertions(+), 5 deletions(-)

The diff of changes is:
diff --git a/debian/changelog b/debian/changelog
index 1392858..2bb8c70 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -2,6 +2,8 @@ python-x2go (0.2.0.7-0~x2go1) UNRELEASED; urgency=low
 
   * New upstream version (0.2.0.7):
     - Refresh server feature list on re-connecting (log-off, log-on).
+    - Fix property method X2goControlSession._x2go_remote_home on broken
+      connections.
 
  -- Mike Gabriel <mike.gabriel at das-netzwerkteam.de>  Mon, 02 Jul 2012 20:57:37 +0200
 
diff --git a/x2go/backends/control/_stdout.py b/x2go/backends/control/_stdout.py
index 2b22b0c..b58445c 100644
--- a/x2go/backends/control/_stdout.py
+++ b/x2go/backends/control/_stdout.py
@@ -462,8 +462,10 @@ class X2goControlSessionSTDOUT(paramiko.SSHClient):
         """
         if self._remote_home is None:
             (stdin, stdout, stderr) = self._x2go_exec_command('echo $HOME')
-            self._remote_home = stdout.read().split()[0]
-            self.logger('remote user\' home directory: %s' % self._remote_home, loglevel=log.loglevel_DEBUG)
+            stdout_r = stdout.read()
+            if stdout_r:
+                self._remote_home = stdout_r.split()[0]
+                self.logger('remote user\' home directory: %s' % self._remote_home, loglevel=log.loglevel_DEBUG)
             return self._remote_home
         else:
             return self._remote_home
@@ -819,13 +821,14 @@ class X2goControlSessionSTDOUT(paramiko.SSHClient):
         ssh_transport._x2go_session_marker = True
         self._session_password = password
 
-        if not self.home_exists():
-            raise x2go_exceptions.X2goRemoteHomeException('remote home directory does not exist')
-
         if self.get_transport():
             self.session_died = False
             self.query_server_features(force=True)
 
+        self._remote_home = None
+        if not self.home_exists():
+            raise x2go_exceptions.X2goRemoteHomeException('remote home directory does not exist')
+
         return (self.get_transport() is not None)
 
     def dissociate(self, terminal_session):


hooks/post-receive
-- 
python-x2go.git (Python X2Go Client API)

This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "python-x2go.git" (Python X2Go Client API).




More information about the x2go-commits mailing list