even better version

This commit is contained in:
rusEfi 2017-04-02 01:15:03 -04:00
parent 616c2295fc
commit 7bed55cd37
1 changed files with 2 additions and 2 deletions

View File

@ -55,8 +55,8 @@ static void SetTimeUnixSec(time_t unix_time) {
canary = localtime_r(&unix_time, &tim);
osalDbgCheck(&tim == canary);
#else
struct tm *t = localtime(&tv_sec);
memcpy(&timp, t, sizeof(struct tm));
struct tm *t = localtime(&unix_time);
memcpy(&tim, t, sizeof(struct tm));
#endif
rtcConvertStructTmToDateTime(&tim, 0, &timespec);