Bug 491630: Make sure DateTime never gets fractional "seconds" in new()

Patch by Max Kanat-Alexander <mkanat@bugzilla.org> r=LpSolit, a=LpSolit


git-svn-id: svn://10.0.0.236/branches/BUGZILLA-3_4-BRANCH@257349 18797224-902f-48f8-a5cc-f745e15eee43
This commit is contained in:
mkanat%bugzilla.org 2009-06-02 03:47:44 +00:00
parent 6ce69b831e
commit fce284b3c0

View File

@ -444,7 +444,8 @@ sub format_time {
day => $time[3],
hour => $time[2],
minute => $time[1],
second => $time[0],
# DateTime doesn't like fractional seconds.
second => int($time[0]),
# If importing, use the specified timezone, otherwise
# use the timezone specified by the server.
time_zone => Bugzilla->local_timezone->offset_as_string($time[6])