summaryrefslogtreecommitdiff
path: root/ace/Malloc_T.cpp
diff options
context:
space:
mode:
authorcoryan <coryan@ae88bc3d-4319-0410-8dbf-d08b4c9d3795>1999-09-02 22:44:17 +0000
committercoryan <coryan@ae88bc3d-4319-0410-8dbf-d08b4c9d3795>1999-09-02 22:44:17 +0000
commit5afa815c1e09aa17273534e14fca477d5956dfa0 (patch)
tree9cddcb77b24029a36760c82c2d3557f5d7e525f2 /ace/Malloc_T.cpp
parent89ab9e8abdbb69cda475459129338473da3f75c3 (diff)
downloadATCD-5afa815c1e09aa17273534e14fca477d5956dfa0.tar.gz
ChangeLogTag:Thu Sep 2 17:42:22 1999 Carlos O'Ryan <coryan@cs.wustl.edu>
Diffstat (limited to 'ace/Malloc_T.cpp')
-rw-r--r--ace/Malloc_T.cpp9
1 files changed, 5 insertions, 4 deletions
diff --git a/ace/Malloc_T.cpp b/ace/Malloc_T.cpp
index 2589f67a3db..c9b00c66ca4 100644
--- a/ace/Malloc_T.cpp
+++ b/ace/Malloc_T.cpp
@@ -168,20 +168,21 @@ ACE_Malloc<ACE_MEM_POOL_2, ACE_LOCK>::open (void)
// Initialize the freelist pointer to point to the dummy
// <ACE_Malloc_Header>.
new ((void *) &this->cb_ptr_->freep_) ACE_MALLOC_HEADER_PTR (&this->cb_ptr_->base_);
+ new ((void *) &this->cb_ptr_->freep_->next_block_) ACE_MALLOC_HEADER_PTR (this->cb_ptr_->freep_.addr ());
new ((void *) &this->cb_ptr_->name_head_) ACE_NAME_NODE_PTR;
+ this->cb_ptr_->freep_->size_ = 0;
#else
// Initialize the freelist pointer to point to the dummy
// <ACE_Malloc_Header>.
this->cb_ptr_->freep_ = &this->cb_ptr_->base_;
// initialize the name list to 0
+ this->cb_ptr_->freep_->size_ = 0;
+ // Initialize the dummy <ACE_Malloc_Header> to point to itself.
+ this->cb_ptr_->freep_->next_block_ = this->cb_ptr_->freep_;
#endif /* ACE_HAS_POSITION_INDEPENDENT_MALLOC */
this->cb_ptr_->name_head_ = (ACE_Name_Node *) 0;
- // Initialize the dummy <ACE_Malloc_Header> to point to itself.
- this->cb_ptr_->freep_->size_ = 0;
- this->cb_ptr_->freep_->next_block_ = this->cb_ptr_->freep_;
-
if (rounded_bytes > (sizeof *this->cb_ptr_ + sizeof (ACE_Malloc_Header)))
{
// If we've got any extra space at the end of the control