summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--ace/Hash_Map_Manager.cpp6
-rw-r--r--ace/Hash_Map_Manager.h8
-rw-r--r--ace/Map_Manager.cpp6
-rw-r--r--ace/Map_Manager.h8
4 files changed, 8 insertions, 20 deletions
diff --git a/ace/Hash_Map_Manager.cpp b/ace/Hash_Map_Manager.cpp
index 492d6f8097d..2d0fc0c1ded 100644
--- a/ace/Hash_Map_Manager.cpp
+++ b/ace/Hash_Map_Manager.cpp
@@ -597,14 +597,10 @@ ACE_Hash_Map_Iterator_Base<EXT_ID, INT_ID, ACE_LOCK>::ACE_Hash_Map_Iterator_Base
int head)
: map_man_ (&mm),
index_ (head != 0 ? -1 : ACE_static_cast (ssize_t, mm.total_size_)),
- next_ (0),
- guard_ (this->map_man_->lock_)
+ next_ (0)
{
ACE_TRACE ("ACE_Hash_Map_Iterator_Base<EXT_ID, INT_ID, ACE_LOCK>::ACE_Hash_Map_Iterator_Base");
- if (this->guard_.locked () == 0)
- return;
-
if (mm.table_ != 0)
this->next_ = &mm.table_[head != 0 ? 0 : mm.total_size_ - 1];
}
diff --git a/ace/Hash_Map_Manager.h b/ace/Hash_Map_Manager.h
index c7559e9f3ef..ff382618459 100644
--- a/ace/Hash_Map_Manager.h
+++ b/ace/Hash_Map_Manager.h
@@ -220,8 +220,9 @@ public:
// Returns a reference to the underlying <ACE_LOCK>. This makes it
// possible to acquire the lock explicitly, which can be useful in
// some cases if you instantiate the <ACE_Atomic_Op> with an
- // <ACE_Recursive_Mutex> or <ACE_Process_Mutex>. NOTE: the right
- // name would be lock_, but HP/C++ will choke on that!
+ // <ACE_Recursive_Mutex> or <ACE_Process_Mutex>, or if you need to
+ // guard the state of an iterator. NOTE: the right name would be
+ // <lock>, but HP/C++ will choke on that!
void dump (void) const;
// Dump the state of an object.
@@ -395,9 +396,6 @@ protected:
ACE_Hash_Map_Entry<EXT_ID, INT_ID> *next_;
// Keeps track of how far we've advanced in a linked list in each
// table slot.
-
- ACE_Read_Guard<ACE_LOCK> guard_;
- // Read guard for the life time of the iterator.
};
template <class EXT_ID, class INT_ID, class ACE_LOCK>
diff --git a/ace/Map_Manager.cpp b/ace/Map_Manager.cpp
index 8e351ef6529..a5feda84b71 100644
--- a/ace/Map_Manager.cpp
+++ b/ace/Map_Manager.cpp
@@ -610,14 +610,10 @@ ACE_Map_Iterator_Base<EXT_ID, INT_ID, ACE_LOCK>::dump_i (void) const
template <class EXT_ID, class INT_ID, class ACE_LOCK>
ACE_Map_Iterator_Base<EXT_ID, INT_ID, ACE_LOCK>::ACE_Map_Iterator_Base (ACE_Map_Manager<EXT_ID, INT_ID, ACE_LOCK> &mm, int head)
: map_man_ (&mm),
- next_ (-1),
- guard_ (this->map_man_->lock_)
+ next_ (-1)
{
ACE_TRACE ("ACE_Map_Iterator_Base<EXT_ID, INT_ID, ACE_LOCK>::ACE_Map_Iterator_Base");
- if (this->guard_.locked () == 0)
- return;
-
if (head == 0)
this->next_ = this->map_man_->cur_size_;
}
diff --git a/ace/Map_Manager.h b/ace/Map_Manager.h
index 0e3c0b4fbb6..cbcb6a5a76f 100644
--- a/ace/Map_Manager.h
+++ b/ace/Map_Manager.h
@@ -178,8 +178,9 @@ public:
// Returns a reference to the underlying <ACE_LOCK>. This makes it
// possible to acquire the lock explicitly, which can be useful in
// some cases if you instantiate the <ACE_Atomic_Op> with an
- // <ACE_Recursive_Mutex> or <ACE_Process_Mutex>. NOTE: the right
- // name would be lock_, but HP/C++ will choke on that!
+ // <ACE_Recursive_Mutex> or <ACE_Process_Mutex>, or if you need to
+ // guard the state of an iterator. NOTE: the right name would be
+ // <lock>, but HP/C++ will choke on that!
void dump (void) const;
// Dump the state of an object.
@@ -337,9 +338,6 @@ protected:
ssize_t next_;
// Keeps track of how far we've advanced...
-
- ACE_Read_Guard<ACE_LOCK> guard_;
- // Read guard for the life time of the iterator.
};
template <class EXT_ID, class INT_ID, class ACE_LOCK>