summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJohnny Willemsen <jwillemsen@remedy.nl>2006-07-20 08:54:49 +0000
committerJohnny Willemsen <jwillemsen@remedy.nl>2006-07-20 08:54:49 +0000
commit1f32b3604988f99b179dbdf466b8156d8686ba80 (patch)
tree06c6ba5650e286e18f940cefe1c14f309a856ec0
parentff52e9ec950a3248ade5aa1d1246bacf1ce037c2 (diff)
downloadATCD-1f32b3604988f99b179dbdf466b8156d8686ba80.tar.gz
ChangeLogTag: Thu Jul 20 08:17:12 UTC 2006 Johnny Willemsen <jwillemsen@remedy.nl>
-rw-r--r--ace/Mutex.cpp2
-rw-r--r--ace/Mutex.h2
-rw-r--r--ace/Mutex.inl8
3 files changed, 6 insertions, 6 deletions
diff --git a/ace/Mutex.cpp b/ace/Mutex.cpp
index 18b95d45b8d..1c45bc6d17d 100644
--- a/ace/Mutex.cpp
+++ b/ace/Mutex.cpp
@@ -40,7 +40,7 @@ ACE_Mutex::ACE_Mutex (int type, const ACE_TCHAR *name,
process_lock_ (0),
lockname_ (0),
#endif /* ACE_HAS_PTHREADS || ACE_HAS_STHREADS */
- removed_ (0)
+ removed_ (false)
{
// ACE_TRACE ("ACE_Mutex::ACE_Mutex");
diff --git a/ace/Mutex.h b/ace/Mutex.h
index 81155d08dc4..2a1d05135a8 100644
--- a/ace/Mutex.h
+++ b/ace/Mutex.h
@@ -171,7 +171,7 @@ public:
/// destructor. This flag isn't protected by a lock, so make sure
/// that you don't have multiple threads simultaneously calling
/// @c remove on the same object, which is a bad idea anyway.
- int removed_;
+ bool removed_;
private:
// Prevent assignment and initialization.
diff --git a/ace/Mutex.inl b/ace/Mutex.inl
index 17f81171553..eb09217501d 100644
--- a/ace/Mutex.inl
+++ b/ace/Mutex.inl
@@ -137,9 +137,9 @@ ACE_Mutex::remove (void)
// shm_open needs to be deleted as well.
if (this->process_lock_)
{
- if (this->removed_ == 0)
+ if (this->removed_ == false)
{
- this->removed_ = 1;
+ this->removed_ = true;
// Only destroy the lock if we're the ones who initialized
// it.
if (!this->lockname_)
@@ -160,9 +160,9 @@ ACE_Mutex::remove (void)
else
{
#else /* !ACE_HAS_PTHREADS && !ACE_HAS_STHREADS */
- if (this->removed_ == 0)
+ if (this->removed_ == false)
{
- this->removed_ = 1;
+ this->removed_ = true;
result = ACE_OS::mutex_destroy (&this->lock_);
}
#endif /* ACE_HAS_PTHREADS || ACE_HAS_STHREADS */