diff options
author | mk1 <mk1@ae88bc3d-4319-0410-8dbf-d08b4c9d3795> | 2001-10-28 19:15:14 +0000 |
---|---|---|
committer | mk1 <mk1@ae88bc3d-4319-0410-8dbf-d08b4c9d3795> | 2001-10-28 19:15:14 +0000 |
commit | 9738b1ad41774bd4d5086322d48793238c8694a7 (patch) | |
tree | 7aaaac48d29dabf36c646d4830cdba22e97a7e13 /ace/Unbounded_Queue.cpp | |
parent | af4cd25a55a9c357b2c04823663bc93e70c0b657 (diff) | |
download | ATCD-9738b1ad41774bd4d5086322d48793238c8694a7.tar.gz |
ChangeLogTag: Sun Oct 28 13:15:00 2001 Michael Kircher <Michael.Kircher@mchp.siemens.de>
Diffstat (limited to 'ace/Unbounded_Queue.cpp')
-rw-r--r-- | ace/Unbounded_Queue.cpp | 13 |
1 files changed, 8 insertions, 5 deletions
diff --git a/ace/Unbounded_Queue.cpp b/ace/Unbounded_Queue.cpp index dd0f81d5079..4413c51f6f9 100644 --- a/ace/Unbounded_Queue.cpp +++ b/ace/Unbounded_Queue.cpp @@ -162,7 +162,8 @@ ACE_Unbounded_Queue<T>::enqueue_head (const T &new_item) // Create a new node that points to the original head. ACE_NEW_MALLOC_RETURN (temp, - (ACE_Node<T> *) this->allocator_->malloc (sizeof (ACE_Node<T>)), + ACE_static_cast(ACE_Node<T> *, + this->allocator_->malloc (sizeof (ACE_Node<T>))), ACE_Node<T> (new_item, this->head_->next_), -1); // Link this pointer into the front of the list. Note that the @@ -179,17 +180,19 @@ ACE_Unbounded_Queue<T>::enqueue_tail (const T &new_item) { // ACE_TRACE ("ACE_Unbounded_Queue<T>::enqueue_tail"); - ACE_Node<T> *temp; - // Insert <item> into the old dummy node location. Note that this // isn't actually the "head" item in the queue, it's a dummy node at // the "tail" of the queue... this->head_->item_ = new_item; + ACE_Node<T> *temp; + // Create a new dummy node. ACE_NEW_MALLOC_RETURN (temp, - (ACE_Node<T> *) this->allocator_->malloc (sizeof (ACE_Node<T>)), - ACE_Node<T> (this->head_->next_), -1); + ACE_static_cast(ACE_Node<T> *, + this->allocator_->malloc (sizeof (ACE_Node<T>))), + ACE_Node<T> (this->head_->next_), + -1); // Link this dummy pointer into the list. this->head_->next_ = temp; |