[X2Go-Commits] python-x2go.git - build-baikal (branch) updated: 0.1.0.3-18-g2e6f672
X2Go dev team
git-admin at x2go.org
Wed Jan 8 15:30:31 CET 2014
The branch, build-baikal has been updated
via 2e6f672fc9127f84cbc0b9d8f42c39f0a44a0565 (commit)
from 49301f618fa80662ce7b1ababc36f7c1e1d5abf3 (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:
x2go/session.py | 44 +++++++++++++++++++++++++-------------------
1 file changed, 25 insertions(+), 19 deletions(-)
The diff of changes is:
diff --git a/x2go/session.py b/x2go/session.py
index 7278e34..52cb682 100644
--- a/x2go/session.py
+++ b/x2go/session.py
@@ -704,16 +704,22 @@ class X2goSession(object):
_params.update(self.control_params)
_params.update(self.sshproxy_params)
- self.connected = self.control_session.connect(self.server,
- use_sshproxy=self.use_sshproxy,
- session_instance=self,
- **_params)
- # remove credentials immediately
- self.control_params['password'] = ''
- try: del self.sshproxy_params['sshproxy_user']
- except KeyError: pass
- try: del self.sshproxy_params['sshproxy_password']
- except KeyError: pass
+ try:
+ self.connected = self.control_session.connect(self.server,
+ use_sshproxy=self.use_sshproxy,
+ session_instance=self,
+ **_params)
+ except:
+ # remove credentials immediately
+ self.control_params['password'] = ''
+ if self.sshproxy_params and self.sshproxy_params.has_key('sshproxy_password'):
+ del self.sshproxy_params['sshproxy_password']
+ raise
+ finally:
+ # remove credentials immediately
+ self.control_params['password'] = ''
+ if self.sshproxy_params and self.sshproxy_params.has_key('sshproxy_password'):
+ del self.sshproxy_params['sshproxy_password']
if not self.connected:
# then tidy up...
@@ -932,33 +938,34 @@ class X2goSession(object):
if _terminal is not None:
- if SUPPORTED_SOUND and _terminal.params.snd_system is not 'none':
+ self.terminal_session = _terminal
+ if SUPPORTED_SOUND and self.terminal_session.params.snd_system is not 'none':
_terminal.start_sound()
if (SUPPORTED_PRINTING and self.printing) or \
(SUPPORTED_MIMEBOX and self.allow_mimebox) or \
(SUPPORTED_FOLDERSHARING and self.allow_share_local_folders):
- _terminal.start_sshfs()
+ self.terminal_session.start_sshfs()
try:
if SUPPORTED_PRINTING and self.printing:
- _terminal.start_printing()
- self.session_environment.update({'X2GO_SPOOLDIR': _terminal.get_printing_spooldir(), })
+ self.terminal_session.start_printing()
+ self.session_environment.update({'X2GO_SPOOLDIR': self.terminal_session.get_printing_spooldir(), })
except X2goUserException:
pass
if SUPPORTED_MIMEBOX and self.allow_mimebox:
- _terminal.start_mimebox(mimebox_extensions=self.mimebox_extensions, mimebox_action=self.mimebox_action)
- self.session_environment.update({'X2GO_MIMEBOX': _terminal.get_mimebox_spooldir(), })
+ self.terminal_session.start_mimebox(mimebox_extensions=self.mimebox_extensions, mimebox_action=self.mimebox_action)
+ self.session_environment.update({'X2GO_MIMEBOX': self.terminal_session.get_mimebox_spooldir(), })
if SUPPORTED_FOLDERSHARING and self.share_local_folders:
- if _control.get_transport().reverse_tunnels[_terminal.get_session_name()]['sshfs'][1] is not None:
+ if _control.get_transport().reverse_tunnels[self.terminal_session.get_session_name()]['sshfs'][1] is not None:
for _folder in self.share_local_folders:
self.share_local_folder(_folder)
# only run the session startup command if we do not resume...
if _new_session:
- _terminal.run_command(env=self.session_environment)
+ self.terminal_session.run_command(env=self.session_environment)
self.virgin = False
self.suspended = False
@@ -966,7 +973,6 @@ class X2goSession(object):
self.terminated = False
self.faulty = False
- self.terminal_session = _terminal
return True
else:
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