mirror of
https://github.com/glest/glest-source.git
synced 2025-08-08 17:36:30 +02:00
- fixed a bunch of memory leaks that will hopefully mean less overall memory requirements.
This commit is contained in:
@@ -93,7 +93,7 @@ protected:
|
||||
public:
|
||||
|
||||
CacheManager() { }
|
||||
~CacheManager() {
|
||||
static void cleanupMutexes() {
|
||||
for(std::map<string, Mutex *>::iterator iterMap = itemCacheMutexList.begin();
|
||||
iterMap != itemCacheMutexList.end(); iterMap++) {
|
||||
delete iterMap->second;
|
||||
@@ -101,6 +101,9 @@ public:
|
||||
}
|
||||
itemCacheMutexList.clear();
|
||||
}
|
||||
~CacheManager() {
|
||||
CacheManager::cleanupMutexes();
|
||||
}
|
||||
|
||||
template <typename T>
|
||||
static void setCachedItem(string cacheKey, const T value) {
|
||||
|
Reference in New Issue
Block a user