[X2Go-Commits] [x2goclient] 01/01: Fix crashing client when editing session from SessionManageDialog.

git-admin at x2go.org git-admin at x2go.org
Tue Dec 1 15:07:18 CET 2015


This is an automated email from the git hooks/post-receive script.

x2go pushed a commit to branch master
in repository x2goclient.

commit daa9cf51927cc142794d2648a9c0279c7106f32a
Author: Oleksandr Shneyder <o.shneyder at phoca-gmbh.de>
Date:   Tue Dec 1 15:07:08 2015 +0100

    Fix crashing client when editing session from SessionManageDialog.
---
 debian/changelog            |    1 +
 src/sessionmanagedialog.cpp |    7 +++++--
 2 files changed, 6 insertions(+), 2 deletions(-)

diff --git a/debian/changelog b/debian/changelog
index fce70b7..985b168 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -13,6 +13,7 @@ x2goclient (4.0.5.1-0x2go1) UNRELEASED; urgency=low
       connections. (Fixes: #772).
     - Replace "::" with "_" for the desktop link name on Windows.
     - Fix direct RDP in broker mode.
+    - Fix crashing client when editing session from SessionManageDialog.
 
   [ Mike Gabriel ]
   * New upstream release (4.0.5.1):
diff --git a/src/sessionmanagedialog.cpp b/src/sessionmanagedialog.cpp
index 5ec0331..c9d287b 100644
--- a/src/sessionmanagedialog.cpp
+++ b/src/sessionmanagedialog.cpp
@@ -202,12 +202,15 @@ void SessionManageDialog::slot_endisable ( QTreeWidgetItem* item, int col)
 {
     Q_UNUSED (col);
 
-    bool isSess=item->data(0, SESSIONROLE).toBool();
+    bool isSess=(item && item->data(0, SESSIONROLE).toBool());
     x2goDebug << "slot_endisable: isSess: " << isSess;
 
     if(!isSess)
     {
-        currentPath=item->data(0,Qt::UserRole).toString().split("/",QString::SkipEmptyParts).join("/");
+        if(item)
+            currentPath=item->data(0,Qt::UserRole).toString().split("/",QString::SkipEmptyParts).join("/");
+        else
+	    currentPath="/";
         x2goDebug << "slot_endisable: no session, currentPath(?): " << currentPath;
     }
 

--
Alioth's /srv/git/code.x2go.org/x2goclient.git//..//_hooks_/post-receive-email on /srv/git/code.x2go.org/x2goclient.git


More information about the x2go-commits mailing list