mirror of
https://github.com/glest/glest-source.git
synced 2025-09-25 23:19:07 +02:00
- added a very useful way to track mutex usage and performance timings of mutex locking to discover thread lock issues
This commit is contained in:
@@ -441,7 +441,7 @@ void SystemFlags::logDebugEntry(DebugType type, string debugEntry, time_t debugT
|
||||
}
|
||||
|
||||
if(currentDebugLog.fileStream->is_open() == true) {
|
||||
MutexSafeWrapper safeMutex(currentDebugLog.mutex);
|
||||
MutexSafeWrapper safeMutex(currentDebugLog.mutex,string(__FILE__) + "_" + intToStr(__LINE__));
|
||||
|
||||
(*currentDebugLog.fileStream) << "Starting Mega-Glest logging for type: " << type << "\n";
|
||||
(*currentDebugLog.fileStream).flush();
|
||||
@@ -453,7 +453,7 @@ void SystemFlags::logDebugEntry(DebugType type, string debugEntry, time_t debugT
|
||||
assert(currentDebugLog.fileStream != NULL);
|
||||
|
||||
if(currentDebugLog.fileStream->is_open() == true) {
|
||||
MutexSafeWrapper safeMutex(currentDebugLog.mutex);
|
||||
MutexSafeWrapper safeMutex(currentDebugLog.mutex,string(__FILE__) + "_" + intToStr(__LINE__));
|
||||
|
||||
// All items in the if clause we don't want timestamps
|
||||
if (type != debugPathFinder && type != debugError && type != debugWorldSynch) {
|
||||
|
Reference in New Issue
Block a user