mirror of
https://github.com/glest/glest-source.git
synced 2025-08-25 17:20:43 +02:00
- thread safe localtime and hopefully back to good performance
This commit is contained in:
@@ -454,8 +454,9 @@ void SystemFlags::logDebugEntry(DebugType type, string debugEntry, time_t debugT
|
||||
// Get the current time.
|
||||
// time_t curtime = time (NULL);
|
||||
// Convert it to local time representation.
|
||||
struct tm *loctime = localtime (&debugTime);
|
||||
strftime(szBuf2,100,"%Y-%m-%d %H:%M:%S",loctime);
|
||||
//struct tm *loctime = localtime (&debugTime);
|
||||
std::tm loctime = threadsafe_localtime(debugTime);
|
||||
strftime(szBuf2,100,"%Y-%m-%d %H:%M:%S",&loctime);
|
||||
}
|
||||
/*
|
||||
va_list argList;
|
||||
|
Reference in New Issue
Block a user