diff options
author | Thiago Macieira <thiago.macieira@intel.com> | 2012-08-11 12:18:45 +0200 |
---|---|---|
committer | Qt by Nokia <qt-info@nokia.com> | 2012-09-14 03:45:50 +0200 |
commit | d8eb52fc45d0209a07b07be2c0f54a9167704574 (patch) | |
tree | 6ad42f3182237d2720a48a408e0bcbc5bb49dc92 /src/corelib/thread/qmutex.cpp | |
parent | fc174a37283306f3f5c06efeda22d5164820c164 (diff) |
Split the timed mutex lock from the non-timed lock functions
Non-timed mutex locks are by far more common, so let's try not to
penalise the locking of those with code that won't get used that
often.
Change-Id: I37f56d6429836467fdec2e588c0fb22d914b5d75
Reviewed-by: Lars Knoll <lars.knoll@nokia.com>
Diffstat (limited to 'src/corelib/thread/qmutex.cpp')
-rw-r--r-- | src/corelib/thread/qmutex.cpp | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/src/corelib/thread/qmutex.cpp b/src/corelib/thread/qmutex.cpp index 2906a5a198..35bb3ac78e 100644 --- a/src/corelib/thread/qmutex.cpp +++ b/src/corelib/thread/qmutex.cpp @@ -361,6 +361,14 @@ bool QBasicMutex::isRecursive() /*! \internal helper for lock() */ +void QBasicMutex::lockInternal() QT_MUTEX_LOCK_NOEXCEPT +{ + lockInternal(-1); +} + +/*! + \internal helper for lock(int) + */ bool QBasicMutex::lockInternal(int timeout) QT_MUTEX_LOCK_NOEXCEPT { Q_ASSERT(!isRecursive()); |