Commit 21e9d6a7 authored by Mike Hibler's avatar Mike Hibler

In timestamp function, print out usecs as %06d (i.e., zero padded).

parent 30ede0ce
#!/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
#
......@@ -313,7 +313,8 @@ 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()
......
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