summaryrefslogtreecommitdiff
path: root/ace
diff options
context:
space:
mode:
authorschmidt <douglascraigschmidt@users.noreply.github.com>1998-10-15 23:34:12 +0000
committerschmidt <douglascraigschmidt@users.noreply.github.com>1998-10-15 23:34:12 +0000
commit29c952df4f242f0f7efc0f575669852da93c6514 (patch)
tree84fa22f2244708b1ab49195e05669fd6ed0644de /ace
parentebdd6a648f8b85b427ef34d942765a90c81e6c40 (diff)
downloadATCD-29c952df4f242f0f7efc0f575669852da93c6514.tar.gz
.
Diffstat (limited to 'ace')
-rw-r--r--ace/Hash_Map_Manager.cpp12
-rw-r--r--ace/Hash_Map_Manager.h8
-rw-r--r--ace/Map_Manager.cpp11
-rw-r--r--ace/Map_Manager.h8
-rw-r--r--ace/OS.h7
5 files changed, 27 insertions, 19 deletions
diff --git a/ace/Hash_Map_Manager.cpp b/ace/Hash_Map_Manager.cpp
index d673aebe713..03128e452c5 100644
--- a/ace/Hash_Map_Manager.cpp
+++ b/ace/Hash_Map_Manager.cpp
@@ -771,9 +771,8 @@ ACE_Hash_Map_Iterator<EXT_ID, INT_ID, ACE_LOCK>::operator++ (void)
ACE_TRACE ("ACE_Hash_Map_Iterator<EXT_ID, INT_ID, ACE_LOCK>::operator++ (void)");
ACE_READ_GUARD_RETURN (ACE_LOCK, ace_mon, this->map_man_->lock_, *this);
- ACE_Hash_Map_Iterator<EXT_ID, INT_ID, ACE_LOCK> retv (*this);
this->forward_i ();
- return retv;
+ return *this;
}
template <class EXT_ID, class INT_ID, class ACE_LOCK>
@@ -783,8 +782,9 @@ ACE_Hash_Map_Iterator<EXT_ID, INT_ID, ACE_LOCK>::operator++ (int)
ACE_TRACE ("ACE_Hash_Map_Iterator<EXT_ID, INT_ID, ACE_LOCK>::operator++ (int)");
ACE_READ_GUARD_RETURN (ACE_LOCK, ace_mon, this->map_man_->lock_, *this);
+ ACE_Hash_Map_Iterator<EXT_ID, INT_ID, ACE_LOCK> retv (*this);
this->forward_i ();
- return *this;
+ return retv;
}
template <class EXT_ID, class INT_ID, class ACE_LOCK>
@@ -794,9 +794,8 @@ ACE_Hash_Map_Iterator<EXT_ID, INT_ID, ACE_LOCK>::operator-- (void)
ACE_TRACE ("ACE_Hash_Map_Iterator<EXT_ID, INT_ID, ACE_LOCK>::operator-- (void)");
ACE_READ_GUARD_RETURN (ACE_LOCK, ace_mon, this->map_man_->lock_, *this);
- ACE_Hash_Map_Iterator<EXT_ID, INT_ID, ACE_LOCK> retv (*this);
this->reverse_i ();
- return retv;
+ return *this;
}
template <class EXT_ID, class INT_ID, class ACE_LOCK>
@@ -806,8 +805,9 @@ ACE_Hash_Map_Iterator<EXT_ID, INT_ID, ACE_LOCK>::operator-- (int)
ACE_TRACE ("ACE_Hash_Map_Iterator<EXT_ID, INT_ID, ACE_LOCK>::operator-- (int)");
ACE_READ_GUARD_RETURN (ACE_LOCK, ace_mon, this->map_man_->lock_, *this);
+ ACE_Hash_Map_Iterator<EXT_ID, INT_ID, ACE_LOCK> retv (*this);
this->reverse_i ();
- return *this;
+ return retv;
}
ACE_ALLOC_HOOK_DEFINE(ACE_Hash_Map_Reverse_Iterator)
diff --git a/ace/Hash_Map_Manager.h b/ace/Hash_Map_Manager.h
index 8b7d8caf592..41389837d0f 100644
--- a/ace/Hash_Map_Manager.h
+++ b/ace/Hash_Map_Manager.h
@@ -421,16 +421,16 @@ public:
// = STL styled iteration, compare, and reference functions.
ACE_Hash_Map_Iterator<EXT_ID, INT_ID, ACE_LOCK> operator++ (void);
- // Postfix advance.
+ // Prefix advance.
ACE_Hash_Map_Iterator<EXT_ID, INT_ID, ACE_LOCK>& operator++ (int);
- // Prefix advance.
+ // Postfix advance.
ACE_Hash_Map_Iterator<EXT_ID, INT_ID, ACE_LOCK> operator-- (void);
- // Postfix advance.
+ // Prefix advance.
ACE_Hash_Map_Iterator<EXT_ID, INT_ID, ACE_LOCK>& operator-- (int);
- // Prefix advance.
+ // Postfix advance.
ACE_ALLOC_HOOK_DECLARE;
// Declare the dynamic allocation hooks.
diff --git a/ace/Map_Manager.cpp b/ace/Map_Manager.cpp
index 98662f96786..ec88ea06c96 100644
--- a/ace/Map_Manager.cpp
+++ b/ace/Map_Manager.cpp
@@ -743,10 +743,9 @@ ACE_Map_Iterator<EXT_ID, INT_ID, ACE_LOCK>
ACE_Map_Iterator<EXT_ID, INT_ID, ACE_LOCK>::operator++ (void)
{
ACE_TRACE ("ACE_Map_Iterator<EXT_ID, INT_ID, ACE_LOCK>::operator++ (void)");
- ACE_Map_Iterator<EXT_ID, INT_ID, ACE_LOCK> retv (*this);
this->forward_i ();
- return retv;
+ return *this;
}
template <class EXT_ID, class INT_ID, class ACE_LOCK>
@@ -754,8 +753,9 @@ ACE_Map_Iterator<EXT_ID, INT_ID, ACE_LOCK>&
ACE_Map_Iterator<EXT_ID, INT_ID, ACE_LOCK>::operator++ (int)
{
ACE_TRACE ("ACE_Map_Iterator<EXT_ID, INT_ID, ACE_LOCK>::operator++ (int)");
- this->forward_i ();
- return *this;
+
+ this->reverse_i ();
+ return retv;
}
template <class EXT_ID, class INT_ID, class ACE_LOCK>
@@ -765,7 +765,8 @@ ACE_Map_Iterator<EXT_ID, INT_ID, ACE_LOCK>::operator-- (void)
ACE_TRACE ("ACE_Map_Iterator<EXT_ID, INT_ID, ACE_LOCK>::operator-- (void)");
ACE_Map_Iterator<EXT_ID, INT_ID, ACE_LOCK> retv (*this);
- this->reverse_i ();
+ ACE_Map_Iterator<EXT_ID, INT_ID, ACE_LOCK> retv (*this);
+ this->forward_i ();
return retv;
}
diff --git a/ace/Map_Manager.h b/ace/Map_Manager.h
index 5416444b95e..ccf48956e4c 100644
--- a/ace/Map_Manager.h
+++ b/ace/Map_Manager.h
@@ -361,16 +361,16 @@ public:
// = STL styled iteration, compare, and reference functions.
ACE_Map_Iterator<EXT_ID, INT_ID, ACE_LOCK> operator++ (void);
- // Postfix advance.
+ // Prefix advance.
ACE_Map_Iterator<EXT_ID, INT_ID, ACE_LOCK>& operator++ (int);
- // Prefix advance.
+ // Postfix advance.
ACE_Map_Iterator<EXT_ID, INT_ID, ACE_LOCK> operator-- (void);
- // Postfix advance.
+ // Prefix advance.
ACE_Map_Iterator<EXT_ID, INT_ID, ACE_LOCK>& operator-- (int);
- // Prefix advance.
+ // Postfix advance.
ACE_ALLOC_HOOK_DECLARE;
// Declare the dynamic allocation hooks.
diff --git a/ace/OS.h b/ace/OS.h
index 38ef19e4851..4a6f6522e2e 100644
--- a/ace/OS.h
+++ b/ace/OS.h
@@ -6374,6 +6374,13 @@ ACE_Auto_Basic_Array_Ptr<char> (ACE_WString (WIDE_STRING).char_rep ()).get ()
# define ACE_NTOHL(X) X
# endif /* ACE_LITTLE_ENDIAN */
+#if defined (ACE_LITTLE_ENDIAN)
+#define ACE_HTONS(x) ACE_SWAP_WORD(x)
+#define ACE_NTOHS(x) ACE_SWAP_WORD(x)
+#else
+#define ACE_HTONS(x) x
+#define ACE_NTOHS(x) x
+#endif /* ACE_LITTLE_ENDIAN */
#if defined (ACE_HAS_AIO_CALLS)
// = Giving unique ACE scoped names for some important