Commit 3e01fcdd authored by Mike Hibler's avatar Mike Hibler

Change goofy HH:MM:SS:uuuuuu timestamp to HH:MM:SS.uuuuuu ('.' not ':')

parent 7c40bc46
#!/usr/bin/perl -w
#
# Copyright (c) 2000-2014 University of Utah and the Flux Group.
# Copyright (c) 2000-2015 University of Utah and the Flux Group.
#
# {{{EMULAB-LICENSE
#
......@@ -3653,7 +3653,8 @@ sub TBTimeStamp()
import POSIX qw(strftime);
$imported_POSIX = 1;
}
return POSIX::strftime("%H:%M:%S", localtime($seconds)) . ":$microseconds";
return POSIX::strftime("%H:%M:%S", localtime($seconds)) . "." .
sprintf("%06d", $microseconds);
}
sub TBTimeStampWithDate()
......@@ -3672,8 +3673,8 @@ sub TBTimeStampWithDate()
$imported_POSIX = 1;
}
return POSIX::strftime("%m/%d/20%y %H:%M:%S", localtime($seconds))
. ":$microseconds";
return POSIX::strftime("%m/%d/20%y %H:%M:%S", localtime($seconds)) . "." .
sprintf("%06d", $microseconds);
}
#
......
#!/usr/bin/perl -wT
#
# Copyright (c) 2000-2014 University of Utah and the Flux Group.
# Copyright (c) 2000-2015 University of Utah and the Flux Group.
#
# {{{EMULAB-LICENSE
#
......@@ -205,16 +205,16 @@ sub TBTimeStamp()
{
my ($seconds, $microseconds) = gettimeofday();
return POSIX::strftime("%H:%M:%S", localtime($seconds)) . ":$microseconds";
return POSIX::strftime("%H:%M:%S", localtime($seconds)) . "." .
sprintf("%06d", $microseconds);
}
sub TBTimeStampWithDate()
{
my ($seconds, $microseconds) = gettimeofday();
return POSIX::strftime("%m/%d/20%y %H:%M:%S", localtime($seconds))
. ":$microseconds";
return POSIX::strftime("%m/%d/20%y %H:%M:%S", localtime($seconds)) . "." .
sprintf("%06d", $microseconds);
}
#
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment