From: Bill Erickson Date: Wed, 2 Dec 2015 22:40:31 +0000 (-0500) Subject: JBAS-980 throttle_disbatcher.pl time printing fix X-Git-Url: https://old-git.evergreen-ils.org/?a=commitdiff_plain;h=4aacc63f9401b603d057a58c335fc6aaa5063735;p=working%2FEvergreen.git JBAS-980 throttle_disbatcher.pl time printing fix Code previously displayed "Time::tm=ARRAY(0xe1e4f8)" instead of a time string. Signed-off-by: Bill Erickson --- diff --git a/KCLS/linking/throttle_disbatcher.pl b/KCLS/linking/throttle_disbatcher.pl index 12bee51540..affa9dc965 100755 --- a/KCLS/linking/throttle_disbatcher.pl +++ b/KCLS/linking/throttle_disbatcher.pl @@ -28,7 +28,7 @@ use Getopt::Long; use Time::localtime; -use POSIX qw/:sys_wait_h/; +use POSIX qw/:sys_wait_h strftime/; $SIG{CHLD} = \&sig_handler; @@ -143,8 +143,9 @@ sub dispatch { } elsif ($pid) { $running++; $now_time = localtime; - print "$count of $goal processed at " . $now_time . "\n" if ($verbose && $count); - print($now_time . ": dispatched: $command\n") if ($verbose); + my $now_string = strftime("%a %b %e %H:%M:%S %Y", CORE::localtime); + print "$count of $goal processed at $now_string\n" if ($verbose && $count); + print($now_string . ": dispatched: $command\n") if ($verbose); print $running . " processes running\n" if ($verbose); } elsif ($pid == 0) { exec($command);