[X2Go-Commits] x2goserver.git - build-baikal (branch) updated: 3.1.1.3-320-g968b9ea

X2Go dev team git-admin at x2go.org
Fri Jan 3 20:51:59 CET 2014


The branch, build-baikal has been updated
       via  968b9eaefce8f4ea1d3b50d73c1e1b16357dcd05 (commit)
      from  66e2f2dfed8d47af30056143f7f336d931715a5e (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 -----------------------------------------------------------------
-----------------------------------------------------------------------

Summary of changes:
 X2Go/SupeReNicer.pm |   14 +++++++-------
 debian/changelog    |    1 +
 2 files changed, 8 insertions(+), 7 deletions(-)

The diff of changes is:
diff --git a/X2Go/SupeReNicer.pm b/X2Go/SupeReNicer.pm
index 34d04a2..0df187b 100644
--- a/X2Go/SupeReNicer.pm
+++ b/X2Go/SupeReNicer.pm
@@ -34,7 +34,7 @@ X2Go::SupeReNicer Perl package.
 
 use strict;
 use Sys::Syslog qw( :standard :macros );
-use X2Go::Utils qw( sanitizer clups );
+use X2Go::Utils qw( sanitizer clups system_capture_stdout_output );
 
 use base 'Exporter';
 
@@ -79,7 +79,7 @@ sub superenice {
 	my $forceUSERrenice = shift; $forceUSERrenice = 0 unless defined $forceUSERrenice;
 	#Path to the "x2golistsessions_root" perl script...
 
-	my $x2golsrpath = `x2gopath base` . "/sbin/x2golistsessions_root";
+	my $x2golsrpath = system_capture_stdout_output("x2gopath", "base") . "/sbin/x2golistsessions_root";
 
 	###########################################################################################
 	# Load list of users to "ignore". These users will never be reniced...
@@ -125,7 +125,7 @@ sub superenice {
 						# If nice level is not normal, renice to normal...
 						syslog('notice', "ReNicing \"$userID\" to level $normalNL for session \"$x2gosid\"");
 						# For the sake of getting a user back to normal ASAP...  We'll renice the entire user not just individual sessions...
-						system("renice -n $normalNL -u $userID 1>/dev/null 2>/dev/null");
+						system("renice", "-n", "$normalNL", "-u", "$userID");
 					}
 
 				} elsif ($x2goState eq "S") {
@@ -143,7 +143,7 @@ sub superenice {
 								open(ENVIRON,"/proc/$pid/environ");my ($Environ,undef) = <ENVIRON>;close(ENVIRON);
 								if ($Environ =~ m/X2GO_SESSION=$x2gosid/) {       # If the x2go Session ID is in environ... renice the pid...
 									#syslog('debug', "$pid: X2GO_SESSION=$x2gosid");
-									system("renice -n $idleNL -p $pid 1>/dev/null 2>/dev/null");
+									system("renice", "-n", "$idleNL", "-p", "$pid");
 								}
 							}
 
@@ -151,7 +151,7 @@ sub superenice {
 						close(AUPS);
 
 						# Renice the AGENT so that we'll know that this one is already reniced.
-						system("renice -n $idleNL -p $agentPid 1>/dev/null 2>/dev/null");
+						system("renice", "-n", "$idleNL", "-p", "$agentPid");
 						syslog('notice', "ReNicing \"$userID\" to level $idleNL for session \"$x2gosid\"");
 
 					}
@@ -204,7 +204,7 @@ sub superenice {
 					# If nice level is not normal, renice to normal...
 					if ($psN ne $normalNL) {
 						syslog('debug', "ReNicing \"$nUser\" to level $normalNL");
-						system("renice -n $normalNL -u $nUser 1>/dev/null 2>/dev/null");
+						system("renice", "-n", "$normalNL", "-u", "$nUser");
 					}
 
 				# State is S (suspended)
@@ -213,7 +213,7 @@ sub superenice {
 					# Did we renice this?
 					if ($psN ne $idleNL) {
 						syslog('debug', "ReNicing \"$nUser\" to level $idleNL");
-						system("renice -n $idleNL -u $nUser 1>/dev/null 2>/dev/null");
+						system("renice", "-n", "$idleNL", "-u", "$nUser");
 					}
 				}
 			}
diff --git a/debian/changelog b/debian/changelog
index 5f84fea..b3a35c9 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -37,6 +37,7 @@ x2goserver (4.1.0.0-0x2go1) UNRELEASED; urgency=low
     - Avoid one argument system calls in x2golistshadowsessions.
     - Provide Perl functions to capture stdout/stderr with multi-argument system
       calls.
+    - Avoid one argument system calls and backticks in SupeReNicer.
   * debian/control:
     + Package X2Go::Log in separate package: libx2go-log-perl.
     + Package X2Go::Server::DB in separate package: libx2go-server-db-perl.


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).




More information about the x2go-commits mailing list