summaryrefslogtreecommitdiff
path: root/src/utility.h
diff options
context:
space:
mode:
Diffstat (limited to 'src/utility.h')
-rw-r--r--src/utility.h12
1 files changed, 7 insertions, 5 deletions
diff --git a/src/utility.h b/src/utility.h
index 84838c0c7..cc8891a07 100644
--- a/src/utility.h
+++ b/src/utility.h
@@ -1766,12 +1766,12 @@ private:
core::list<Value> m_list;
};
-#if 0
+#if 1
template<typename Key, typename Value>
-class MutexedCache
+class MutexedMap
{
public:
- MutexedCache()
+ MutexedMap()
{
m_mutex.Init();
assert(m_mutex.IsInitialized());
@@ -1793,8 +1793,10 @@ public:
if(n == NULL)
return false;
-
- *result = n->getValue();
+
+ if(result != NULL)
+ *result = n->getValue();
+
return true;
}