sub readable_wintime { my $wintime = shift; my $unix_epoch = win_to_unix_epoch($wintime); my ($year, $month, $day, $hour, $minute, $second) = (localtime $unix_epoch)[5,4,3,2,1,0]; $year += 1900; $month += 1; ($month, $day, $hour, $minute, $second) = map { sprintf '%02d', $_ } $month, $day, $hour, $minute, $second; my $date = join('-', $day, $month, $year); my $time = join(':', $hour, $minute, $second); return $date, $time; }