Ticket #8450: c_local_time_adjustor.hpp.patch
File c_local_time_adjustor.hpp.patch, 753 bytes (added by , 10 years ago) |
---|
-
c_local_time_adjustor.hpp
42 42 } 43 43 date_duration_type dd = t.date() - time_t_start_day; 44 44 time_duration_type td = t.time_of_day(); 45 std::time_t t2 = dd.days()*86400 + td.hours()*3600 + td.minutes()*60 + td.seconds();45 std::time_t t2 = static_cast<std::time_t>(dd.days())*86400 + static_cast<std::time_t>(td.hours())*3600 + static_cast<std::time_t>(td.minutes())*60 + td.seconds(); 46 46 std::tm tms, *tms_ptr; 47 47 tms_ptr = c_time::localtime(&t2, &tms); 48 48 date_type d(static_cast<unsigned short>(tms_ptr->tm_year + 1900),