summaryrefslogtreecommitdiffstats
path: root/src/OSSupport/CriticalSection.h
diff options
context:
space:
mode:
authorMattes D <github@xoft.cz>2015-03-24 13:09:41 +0100
committerMattes D <github@xoft.cz>2015-03-24 13:09:41 +0100
commite5a7a730ed4f26eae896c56391bf3d2b5fecb852 (patch)
tree0209c1567f60af60999f3aeeb513a72f9eab2743 /src/OSSupport/CriticalSection.h
parentMerge pull request #1775 from tommysanterre/terrainheightfix (diff)
parentAdded VarInt64, normalized cPacketizer datatype names. (diff)
downloadcuberite-e5a7a730ed4f26eae896c56391bf3d2b5fecb852.tar
cuberite-e5a7a730ed4f26eae896c56391bf3d2b5fecb852.tar.gz
cuberite-e5a7a730ed4f26eae896c56391bf3d2b5fecb852.tar.bz2
cuberite-e5a7a730ed4f26eae896c56391bf3d2b5fecb852.tar.lz
cuberite-e5a7a730ed4f26eae896c56391bf3d2b5fecb852.tar.xz
cuberite-e5a7a730ed4f26eae896c56391bf3d2b5fecb852.tar.zst
cuberite-e5a7a730ed4f26eae896c56391bf3d2b5fecb852.zip
Diffstat (limited to 'src/OSSupport/CriticalSection.h')
-rw-r--r--src/OSSupport/CriticalSection.h12
1 files changed, 6 insertions, 6 deletions
diff --git a/src/OSSupport/CriticalSection.h b/src/OSSupport/CriticalSection.h
index 17fcdfc12..d52f049d2 100644
--- a/src/OSSupport/CriticalSection.h
+++ b/src/OSSupport/CriticalSection.h
@@ -10,22 +10,22 @@
class cCriticalSection
{
public:
-
void Lock(void);
void Unlock(void);
// IsLocked/IsLockedByCurrentThread are only used in ASSERT statements, but because of the changes with ASSERT they must always be defined
// The fake versions (in Release) will not effect the program in any way
#ifdef _DEBUG
- cCriticalSection(void);
- bool IsLocked(void);
- bool IsLockedByCurrentThread(void);
+ cCriticalSection(void);
+ bool IsLocked(void);
+ bool IsLockedByCurrentThread(void);
#else
- bool IsLocked(void) { return false; }
- bool IsLockedByCurrentThread(void) { return false; }
+ bool IsLocked(void) { return false; }
+ bool IsLockedByCurrentThread(void) { return false; }
#endif // _DEBUG
private:
+
#ifdef _DEBUG
int m_IsLocked; // Number of times this CS is locked
std::thread::id m_OwningThreadID;