[X2go-Commits] python-x2go.git - master (branch) updated: 0.1.1.4-181-gac9bcec

X2Go dev team git-admin at x2go.org
Thu Apr 12 15:06:52 CEST 2012


The branch, master has been updated
       via  ac9bcecf496ab76a31bea28fddfa0a1af08faaeb (commit)
      from  295486c5dd26572b86ae9d383557464ac78d4651 (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 -----------------------------------------------------------------
commit ac9bcecf496ab76a31bea28fddfa0a1af08faaeb
Author: Mike Gabriel <mike.gabriel at das-netzwerkteam.de>
Date:   Thu Apr 12 15:06:47 2012 +0200

    Fix X2goSession.get_shared_folders() method on Windows.

-----------------------------------------------------------------------

Summary of changes:
 debian/changelog |    1 +
 x2go/session.py  |   16 ++++++++++++----
 2 files changed, 13 insertions(+), 4 deletions(-)

The diff of changes is:
diff --git a/debian/changelog b/debian/changelog
index 9cb36b8..2838876 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -85,6 +85,7 @@ python-x2go (0.1.2.0-0~x2go1) UNRELEASED; urgency=low
     - Use double-quotes for pulseaudio options.
     - Export X2GO_SESSION and PULSE_CLIENTCONFIG to published applications.
     - When starting pulseaudio on Windows use --exit-idle-time=0.
+    - Fix X2goSession.get_shared_folders() method on Windows.
   * Depend on python-xlib.
 
  -- Mike Gabriel <mike.gabriel at das-netzwerkteam.de>  Sat, 28 Sep 2012 01:44:21 +0100
diff --git a/x2go/session.py b/x2go/session.py
index 49816cf..c74d580 100644
--- a/x2go/session.py
+++ b/x2go/session.py
@@ -52,6 +52,7 @@ from x2go.backends.proxy import X2goProxy as _X2goProxy
 from x2go.backends.settings import X2goClientSettings as _X2goClientSettings
 from x2go.backends.printing import X2goClientPrinting as _X2goClientPrinting
 
+from defaults import X2GOCLIENT_OS as _X2GOCLIENT_OS
 from defaults import LOCAL_HOME as _LOCAL_HOME
 from defaults import X2GO_CLIENT_ROOTDIR as _X2GO_CLIENT_ROOTDIR
 from defaults import X2GO_SESSIONS_ROOTDIR as _X2GO_SESSIONS_ROOTDIR
@@ -1969,10 +1970,17 @@ class X2goSession(object):
 
                 for mount in mounts:
                     mount = mount.split('|')[1]
-                    _mount_point = shared_folder.replace('/', '_')
-                    if mount.endswith(_mount_point):
-                        _found = True
-                        break
+                    if _X2GOCLIENT_OS == 'Windows':
+                        _driveletter, _path = os.path.splitdrive(shared_folder)
+                        _mount_point = '_windrive_%s_%s' % (_driveletter, _path.replace('\\', '_')
+                        if mount.lower().endswith(_mount_point.lower()):
+                            _found = True
+                            break
+                    else:
+                        _mount_point = shared_folder.replace('/', '_')
+                        if mount.endswith(_mount_point):
+                            _found = True
+                            break
 
                 if not _found:
                     unshared_folders.append(shared_folder)


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