Closed Grinnz closed 6 years ago
This issue only became visible because of another issue; the copy constructor always passes its argument to localtime(), which erroneously will interpret a UTC Time::Piece object as localtime and copy it incorrectly. I will open another PR for that issue.
The only time _mktime is called with an array reference not created internally is when using the copy constructor:
Time::Piece->new($obj)
. In this instance, the epoch field of$obj
was inadvertently modified before copying the values to the new object.