[FreeNX-kNX] Nxclient Version 2 and launching commands with switches

ssycplkbocve at spammotel.com ssycplkbocve at spammotel.com
Sat Jul 8 03:53:44 UTC 2006


Hi. I've just installed nxclient version 2 to connect to an existing freenx server version 0.4.4+0.4.5-2sarge1 from backports.org and discoverd that when 'Desktop settings' 'Run the following command' the new nxclient url encodes certain charecters such as 'space', causeing them to fail to launch. So I'm posting my patch that fixes this for me, but will need to be adjusted to work with other freenx versions.

# this file is a patch for /usr/bin/nxserver which is linked from
# /usr/lib/nx/nxserver
# it allows the use of command with parameters in the 'run the following
# command' box with nxclient version 2 and freenx version 0.4.4+0.4.5-2sarge1
# ie: 'xlogo' works wereas 'xlogo -shape' fails due to nxclient version 2, url
# encodeing the space characters into '%20', so that 'xlogo -shape' becomes
# 'xlogo%20-shape', which fails to start

--- /usr/bin/nxserver.orig      2006-07-07 18:33:05.000000000 -0400
+++ /usr/bin/nxserver   2006-07-07 23:41:22.515464632 -0400
@@ -899,6 +899,10 @@
        unset CMD
        read CMD 2>/dev/null
        # FIXME?
+# added by admin because the new version 2 of the nxclient sends url encoded
+# space characters in the command string, causeing commands with trailling
+# parameters to fail. ie: 'xlogo' succeeds and 'xlogo -shape' fails
+CMD="`echo "$CMD"|sed 's/%20/ /g'`"
        [ "$CMD" = "" ] && CMD="quit"

        # Logging




More information about the FreeNX-kNX mailing list