summaryrefslogtreecommitdiff
path: root/src/utils/mutex.h
diff options
context:
space:
mode:
authorThorbjørn Lindeijer <thorbjorn@lindeijer.nl>2012-02-24 21:16:12 +0100
committerThorbjørn Lindeijer <thorbjorn@lindeijer.nl>2012-03-24 22:28:23 +0100
commita5690fa2a4cce2698225f1f558183f6fe306d860 (patch)
tree822d4e237412afd38008de04d9be11fd0718f101 /src/utils/mutex.h
parent054246ebffcdd20da72a8e464b40eaf64d484743 (diff)
downloadmana-a5690fa2a4cce2698225f1f558183f6fe306d860.tar.gz
mana-a5690fa2a4cce2698225f1f558183f6fe306d860.tar.bz2
mana-a5690fa2a4cce2698225f1f558183f6fe306d860.tar.xz
mana-a5690fa2a4cce2698225f1f558183f6fe306d860.zip
Introduced compile-time option to disable use of C++0x
This is in order to still support older compilers, in particular GCC 4.2.1, so that Mana may be compiled for Maemo 5. Reviewed-by: Yohann Ferreira
Diffstat (limited to 'src/utils/mutex.h')
-rw-r--r--src/utils/mutex.h5
1 files changed, 5 insertions, 0 deletions
diff --git a/src/utils/mutex.h b/src/utils/mutex.h
index 26ad754e..f7f26233 100644
--- a/src/utils/mutex.h
+++ b/src/utils/mutex.h
@@ -53,7 +53,9 @@ class MutexLocker
{
public:
MutexLocker(Mutex *mutex);
+#ifdef ENABLE_CPP0X
MutexLocker(MutexLocker&&);
+#endif
~MutexLocker();
private:
@@ -93,11 +95,14 @@ inline MutexLocker::MutexLocker(Mutex *mutex):
mMutex->lock();
}
+#ifdef ENABLE_CPP0X
inline MutexLocker::MutexLocker(MutexLocker&& rhs):
mMutex(rhs.mMutex)
{
rhs.mMutex = NULL;
}
+#endif
+
inline MutexLocker::~MutexLocker()
{
if (mMutex)