diff options
author | schmidt <douglascraigschmidt@users.noreply.github.com> | 1999-03-06 18:57:22 +0000 |
---|---|---|
committer | schmidt <douglascraigschmidt@users.noreply.github.com> | 1999-03-06 18:57:22 +0000 |
commit | 6f29619cd98ee94a45aba98903ba42bb7ce0989b (patch) | |
tree | 9be1b894dc0fbdedff7511f2adef593b9bf066a6 /TAO/tao/MProfile.cpp | |
parent | 2c7b68ad2c3780dc93f81b8495942ad91bc1ed06 (diff) | |
download | ATCD-6f29619cd98ee94a45aba98903ba42bb7ce0989b.tar.gz |
.
Diffstat (limited to 'TAO/tao/MProfile.cpp')
-rw-r--r-- | TAO/tao/MProfile.cpp | 52 |
1 files changed, 28 insertions, 24 deletions
diff --git a/TAO/tao/MProfile.cpp b/TAO/tao/MProfile.cpp index 69c7afd3713..963f4becb77 100644 --- a/TAO/tao/MProfile.cpp +++ b/TAO/tao/MProfile.cpp @@ -15,8 +15,11 @@ TAO_MProfile::set (CORBA::ULong sz) { if (sz == 0) { - // We do, so release all of our profiles. - for (TAO_PHandle h = 0; h < this->size_; h++ ) + // Release all of our profiles. + + for (TAO_PHandle h = 0; + h < this->size_; + h++) if (this->pfiles_[h]) { this->pfiles_[h]->_decr_refcnt (); @@ -26,13 +29,13 @@ TAO_MProfile::set (CORBA::ULong sz) if (this->size_) delete [] this->pfiles_; - if (forward_from_) - delete forward_from_; + if (forward_from_) + delete forward_from_; - pfiles_ = 0; - current_ = 0; - size_ = 0; - last_= 0; + pfiles_ = 0; + current_ = 0; + size_ = 0; + last_= 0; this->pfiles_ = 0; this->current_ = 0; @@ -43,13 +46,15 @@ TAO_MProfile::set (CORBA::ULong sz) } // See if we already have an existing profile list or if we need to - // get ridof what we have. - // @@ Fred, please be consistent with your use of this-> as a prefix - // for data members. + // get ridof what we have. @@ Fred, please be consistent with your + // use of this-> as a prefix for data members. if (size_) { - // We do, so release all of our profiles. - for (TAO_PHandle h = 0; h < size_; h++) + // Release all of our profiles. + + for (TAO_PHandle h = 0; + h < size_; + h++) if (this->pfiles_[h]) { this->pfiles_[h]->_decr_refcnt (); @@ -108,19 +113,18 @@ TAO_MProfile::set (TAO_MProfile *mprofile) // this->forward_from_ = 0; // Now reference all profiles. - for (TAO_PHandle h = 0 ; h < this->size_ ; h++ ) - { - if (mprofile->pfiles_[h]) - { - this->pfiles_[h] = mprofile->pfiles_[h]; - this->pfiles_[h]->_incr_refcnt (); - } - } // for (TAO_PHandle ...) + + for (TAO_PHandle h = 0; + h < this->size_; + h++) + if (mprofile->pfiles_[h]) + { + this->pfiles_[h] = mprofile->pfiles_[h]; + this->pfiles_[h]->_incr_refcnt (); + } if (mprofile->forward_from_) - { - this->forward_from_ = mprofile->forward_from_; - } + this->forward_from_ = mprofile->forward_from_; return 1; } |