summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authormread <qt-info@nokia.com>2011-02-18 10:25:57 (GMT)
committermread <qt-info@nokia.com>2011-03-09 12:47:53 (GMT)
commitc5c7ce758c991e760015fa60194a154e2ecbc622 (patch)
tree302204173899c7480b174caeb7ae7c1119462ca1
parent563c766ced47c1bfb25976e5a8b8668ed9ab0c53 (diff)
downloadQt-c5c7ce758c991e760015fa60194a154e2ecbc622.zip
Qt-c5c7ce758c991e760015fa60194a154e2ecbc622.tar.gz
Qt-c5c7ce758c991e760015fa60194a154e2ecbc622.tar.bz2
Making RFastLock work for QMutex
It needed an initial lock to make it behave like a semaphore. Task-number: QTBUG-13990 Reviewed-by: Shane Kearns
-rw-r--r--src/corelib/thread/qmutex_symbian.cpp2
1 files changed, 2 insertions, 0 deletions
diff --git a/src/corelib/thread/qmutex_symbian.cpp b/src/corelib/thread/qmutex_symbian.cpp
index 09c59af..c5671f5 100644
--- a/src/corelib/thread/qmutex_symbian.cpp
+++ b/src/corelib/thread/qmutex_symbian.cpp
@@ -57,6 +57,8 @@ QMutexPrivate::QMutexPrivate(QMutex::RecursionMode mode)
{
#ifdef QT_SYMBIAN_USE_RFASTLOCK
int r = lock.CreateLocal();
+ if (r == KErrNone)
+ lock.Wait();
#else
int r = lock.CreateLocal(0);
#endif