aboutsummaryrefslogtreecommitdiff
path: root/dep/src/zthread/win32/FastLock.h
diff options
context:
space:
mode:
authorParadox <none@none>2009-02-09 08:16:34 -0500
committerParadox <none@none>2009-02-09 08:16:34 -0500
commitd230302b16474ff22a35243ffed6236ef4fc7fb9 (patch)
treee3679ad841a47b275756f2721f9aa24a3ee548a6 /dep/src/zthread/win32/FastLock.h
parentb0694d7e5e794b361fa178d55fefdb98cf47e9ca (diff)
Replace tabs with spaces in more files.
--HG-- branch : trunk
Diffstat (limited to 'dep/src/zthread/win32/FastLock.h')
-rw-r--r--dep/src/zthread/win32/FastLock.h16
1 files changed, 8 insertions, 8 deletions
diff --git a/dep/src/zthread/win32/FastLock.h b/dep/src/zthread/win32/FastLock.h
index 2e9fe829af6..3b212e1d891 100644
--- a/dep/src/zthread/win32/FastLock.h
+++ b/dep/src/zthread/win32/FastLock.h
@@ -39,10 +39,10 @@ namespace ZThread {
* @version 2.2.11
*
* This FastLock implementation is based on a Win32 Mutex
- * object. This will perform better under high contention,
+ * object. This will perform better under high contention,
* but will not be as fast as the spin lock under reasonable
* circumstances.
- */
+ */
class FastLock : private NonCopyable {
HANDLE _hMutex;
@@ -51,11 +51,11 @@ namespace ZThread {
#endif
public:
-
+
/**
* Create a new FastLock
*/
- FastLock() {
+ FastLock() {
#ifndef NDEBUG
_locked = false;
@@ -68,11 +68,11 @@ namespace ZThread {
}
-
+
~FastLock() {
::CloseHandle(_hMutex);
}
-
+
void acquire() {
if(::WaitForSingleObject(_hMutex, INFINITE) != WAIT_OBJECT_0) {
@@ -113,7 +113,7 @@ namespace ZThread {
switch(::WaitForSingleObject(_hMutex, timeout)) {
case WAIT_OBJECT_0:
-
+
#ifndef NDEBUG
// Simulate deadlock to provide consistent behavior. This
@@ -122,7 +122,7 @@ namespace ZThread {
while(_locked)
ThreadOps::yield();
-
+
_locked = true;
#endif