So, it appears to be well known that 'ss -lxu' has been broken on some systems and returns nothing. This is currently true on EL 7.2 though appears fixed in 7.3 beta.

However, why is -u being passed to ss in the first place?  We're doing:

my $lines=system_capture_stdout_output("ss", "-lxu");
my @lines=split("\n", "$lines");
my @outp = grep ( /(@| )\/tmp\/.X11-unix\/X.*/, @lines);
for(my $i=0;$i<@outp;$i++)

so we're filtering the output of ss for lines that look like unix sockets (/tmp/.X11-unix/X*), so -lx is appropriate. But why use '-u' to show UDP sockets? No X server that I know of listens on UDP and we certainly would filter it out anyway.

diff --git a/x2goserver/bin/x2golistdesktops b/x2goserver/bin/x2golistdesktops
index 386ed17..1cbc7ef 100755
--- a/x2goserver/bin/x2golistdesktops
+++ b/x2goserver/bin/x2golistdesktops
@@ -66,7 +66,7 @@ my $uname=$ENV{'USER'};
 # -> so we need to tweak the PATH env var a little here...
 my $old_PATH=$ENV{'PATH'};
-my $lines=system_capture_stdout_output("ss", "-lxu");
+my $lines=system_capture_stdout_output("ss", "-lx");
 undef $old_PATH;

See also

Orion Poplawski
Technical Manager                     303-415-9701 x222
NWRA/CoRA Division                    FAX: 303-415-9702
3380 Mitchell Lane        
Boulder, CO 80301    
x2go-dev mailing list

Reply via email to