The branch, master has been updated via 322a7f990adab973aa4dd39d5a07688e6020f977 (commit) from a591dd31b532c0fdc98cd051931ac4132ad7b40c (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 322a7f990adab973aa4dd39d5a07688e6020f977 Author: Moritz 'Morty' Strübe <morty@gmx.net> Date: Fri Dec 9 18:52:34 2011 +0100 Make sure the socket used by nxagent is not already in use ----------------------------------------------------------------------- Summary of changes: debian/control | 3 ++- x2goserver/bin/x2gostartagent | 8 ++++++-- 2 files changed, 8 insertions(+), 3 deletions(-) The diff of changes is: diff --git a/debian/control b/debian/control index ff07d92..0a51bcd 100644 --- a/debian/control +++ b/debian/control @@ -27,7 +27,8 @@ Depends: libdbd-sqlite3-perl, adduser, xauth, - psmisc + psmisc, + net-tools Recommends: sshfs, x11-apps, diff --git a/x2goserver/bin/x2gostartagent b/x2goserver/bin/x2gostartagent index e882fdd..a4952bc 100755 --- a/x2goserver/bin/x2gostartagent +++ b/x2goserver/bin/x2gostartagent @@ -120,8 +120,12 @@ USED_DISPLAYS=`$X2GO_LIB_PATH/x2gogetdisplays $HOSTNAME` while [ "$OUTPUT" != "inserted" ]; do X2GO_PORT=$(($X2GO_PORT + 1)) X2GO_PORT=`echo "for(\\$i=$X2GO_PORT;\\$br ne \"true\";\\$i++){ if(\"$USED_DISPLAYS\" =~ m/\\|\\$i\\|/){\\$br=\"false\";}else{\\$br=\"true\";print \\$i;}}"|perl` - - if [ -e "/tmp/.X${X2GO_PORT}-lock" ] || [ -e "/tmp/.X11-unix/X${X2GO_PORT}" ]; then + + #Test if the session is already in use. nxagent uses 6000+DISPLAY to open a port. Therefore this must be tested, too. + NX_PORT=$(($X2GO_PORT + 6000)) + if [ -e "/tmp/.X${X2GO_PORT}-lock" ] || + [ -e "/tmp/.X11-unix/X${X2GO_PORT}" ] || + netstat -ntl 2>/dev/null | grep -q ":${NX_PORT} "; then OUTPUT="XXX" else SESSION_NAME=${USER}-${X2GO_PORT}-`date +"%s"` hooks/post-receive -- x2goserver.git (X2Go Server) 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 "x2goserver.git" (X2Go Server).