Force use of english in uptime command output https://sourceforge.net/p/webadmin/bugs/5337/

This commit is contained in:
Jamie Cameron 2019-12-30 10:02:03 -08:00
parent a589ea9799
commit 65e40fc4ca

View File

@ -41,7 +41,9 @@ $_[0]->{'max'} = $in{'max'};
sub uptime_output
{
local $out = `uptime 2>&1`;
&clean_environment();
local $out = &backquote_command("uptime 2>&1");
&reset_environment();
return $out =~ /average(s)?:\s+([0-9\.]+),?\s+([0-9\.]+),?\s+([0-9\.]+)/i ?
( $2, $3, $4 ) : ( );
}