mirror of
https://github.com/boostorg/date_time.git
synced 2026-07-21 13:13:29 +00:00
Fix from_time_t Y2K38 bug on LLP64 platforms
This commit is contained in:
@@ -26,7 +26,7 @@ namespace posix_time {
|
||||
inline
|
||||
ptime from_time_t(std::time_t t)
|
||||
{
|
||||
return ptime(gregorian::date(1970,1,1)) + seconds(static_cast<long>(t));
|
||||
return ptime(gregorian::date(1970,1,1)) + seconds(t);
|
||||
}
|
||||
|
||||
//! Function that converts a ptime into a time_t
|
||||
|
||||
Reference in New Issue
Block a user