use data race safe gmtime variant as in NormSession::OnReportTimeout (#91)
Co-authored-by: Pat Mills <patrick.m.mills2@boeing.com>norm-ccd
parent
9a613d4150
commit
0c2e151a77
|
|
@ -2628,7 +2628,14 @@ void NormTrace(const struct timeval ¤tTime,
|
|||
struct tm *ct = &timeStruct;
|
||||
#else
|
||||
time_t secs = (time_t)currentTime.tv_sec;
|
||||
struct tm *ct = gmtime(&secs);
|
||||
struct tm timeStruct;
|
||||
#ifdef WIN32
|
||||
gmtime_s(&timeStruct, &secs);
|
||||
struct tm *ct = &timeStruct;
|
||||
#else
|
||||
struct tm *ct = gmtime_r(&secs, &timeStruct);
|
||||
#endif
|
||||
|
||||
#endif // if/else _WIN32_WCE
|
||||
|
||||
PLOG(PL_ALWAYS, "trace>%02d:%02d:%02d.%06lu ",
|
||||
|
|
|
|||
Loading…
Reference in New Issue