[FreeNX-kNX] nxviewer vs vncviewer

chris at ccburton.com chris at ccburton.com
Thu Apr 18 12:00:52 UTC 2013


freenx-knx-bounces at kde.org wrote on 17/04/2013 00:49:03:

> Thanks Chris, for working with me on this!!!
> 
> I've attached a zip with the following 4 files, per your 
> instructions (except I happen to have my nxerver.log in an /nx 
> subdirectory of /var/log):

Right-oh.

I can see it modifying the type= but then ignoring the new value
so . . . a quick look at the code . . . 



If you look through your log file you can see where the code
has updated paramater type  from

        type=vnc
to
        type=vnc-helper

Here is the modified parameter set ( sorry if its wrapped )

&link=lan&backingstore=1&encryption=1&cache=16M&images=64M&shmem=1&shpix=1&strict=0&composite=1&media=0&session=VNC 
2 Forte via Destiny 
NX&type=vnc&agent_server=forte%3A5900&agent_password=******&geometry=1024x768+128+112&client=linux&keyboard=pc102/us&screeninfo=1024x768x24+render&clientproto=3.2.0&login_method=SSH&type=vnc-helper&application=/usr/lib/nx/nxviewer_helper&freenx_export_agents=1&user=mikem&userip=10.0.1.101&uniqueid=181ECAF26280C670703B131ED401722B&display=2000&host=127.0.0.1

The code which accomplishes this is in nxserver

  function server_startrestore_session() from line 1399

  if [ "$ENABLE_EXTERNAL_NXVIEWER" = "1" -a "$(getparam type)" = "vnc" ]
                then
type="vnc-helper"
application="$PATH_BIN/nxviewer_helper"
PARAMS="$PARAMS&type=$type&application=$application&freenx_export_agents=1"
CMDLINE=$PARAMS
                fi

NOTE  the new paramwter is ADDED onto THE END of variable:- PARAMS

AND
if you look back at your parameters you will see two &type=

This is then being ignored, so a quick look at the ubuntu version of
getparam shows why.


This is a classic problem of maintaining old code which you don't fully
understand without testing ALL functionality.

I can't see straight off why any change was neccessary here tho,
so I will add that fixing things which aren't broken in old code
'cos you have a tidy mind, is aone of the greatest ways to
inconvenience any number of (other) people.


***** see attached demonstrator script ******


You have anumber of options for a fix,
the quick one being
 ****   to mod your nxnode back to the old version,****
                 (from the attachment)
until either
the python enthusiast in question produces an update
or
they work through the scripts changing all instances of
"update by append" to "update by replace"
(more uneccessary changes, but once you start on
         olde code
 it's endless)





Let us know how you get on with it  . . . .


cb

ok, what's left of lunch time ????

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.kde.org/pipermail/freenx-knx/attachments/20130418/c473b465/attachment.html>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: freenx-nxnode-getparam-demo-script.sh
Type: application/octet-stream
Size: 3287 bytes
Desc: not available
URL: <http://mail.kde.org/pipermail/freenx-knx/attachments/20130418/c473b465/attachment.obj>


More information about the FreeNX-kNX mailing list