summaryrefslogtreecommitdiff
path: root/TAO
diff options
context:
space:
mode:
authorfrehberger <frehberger@ae88bc3d-4319-0410-8dbf-d08b4c9d3795>2006-03-30 02:34:43 +0000
committerfrehberger <frehberger@ae88bc3d-4319-0410-8dbf-d08b4c9d3795>2006-03-30 02:34:43 +0000
commitb383ac21949dff905e1466ed44e82ed8d0397f3f (patch)
tree560163b98ae732593203d8668ed868fbdee790b3 /TAO
parenta7ad59d89b6ed2d1eb951fea918d8f5170edb38b (diff)
downloadATCD-b383ac21949dff905e1466ed44e82ed8d0397f3f.tar.gz
ChangeLogTag: Thu Mar 30 03:30:00 UTC 2006 Frank Rehberger <frehberger@prismtech.com>
Diffstat (limited to 'TAO')
-rw-r--r--TAO/ChangeLog9
-rw-r--r--TAO/tao/Stub.i58
-rwxr-xr-xTAO/tests/Permanent_Forward/StubTest.cpp24
3 files changed, 45 insertions, 46 deletions
diff --git a/TAO/ChangeLog b/TAO/ChangeLog
index 9b7e0c19e26..d9ad25844d4 100644
--- a/TAO/ChangeLog
+++ b/TAO/ChangeLog
@@ -1,3 +1,12 @@
+Thu Mar 30 03:30:00 UTC 2006 Frank Rehberger <frehberger@prismtech.com>
+ * TAO/tao/Stub.i: add missing call to
+ orb_core->reinitialize_object (this), to optimize for colocal
+ case.
+
+ * TAO/tests/Permanent_Forward/StubTest.cpp: Removed code at end of
+ test, which caused error messages even if the test run thru all
+ test-cases successfully.
+
Wed Mar 29 19:30:00 UTC 2006 Frank Rehberger <frehberger@prismtech.com>
* TAO/tao/Transport.h: Correct the documentation explaining
message parsing. This is related to #2313
diff --git a/TAO/tao/Stub.i b/TAO/tao/Stub.i
index ce5c9237e24..51bc7a28e27 100644
--- a/TAO/tao/Stub.i
+++ b/TAO/tao/Stub.i
@@ -88,47 +88,55 @@ TAO_Stub::next_profile_i (void)
// at bottom of stack
// forward_profiles_
{
+ // In case of permanent forward the base_profiles are ingored.
+
pfile_next = this->next_forward_profile ();
if (pfile_next == 0)
- {
- // reached end of list of permanent forward profiles
- // now, reset forward_profiles_perm_
+ {
+ // COND: this->forward_profiles_ == this->forward_profiles_perm_
- this->forward_profiles_->rewind ();
- this->profile_success_ = false;
+ // reached end of list of permanent forward profiles
+ // now, reset forward_profiles_perm_
+ this->forward_profiles_->rewind ();
+ this->profile_success_ = false;
this->set_profile_in_use_i (this->forward_profiles_->get_next());
- }
+ }
else
this->set_profile_in_use_i (pfile_next);
+ // We may have been forwarded to / from a collocated situation
+ // Check for this and apply / remove optimisation if required.
+ this->orb_core_->reinitialize_object (this);
+
return pfile_next;
}
-
- // Now do the common operation
- if (this->forward_profiles_)
+ else
{
- pfile_next = this->next_forward_profile ();
- if (pfile_next == 0)
+ if (this->forward_profiles_) // Now do the common operation
{
- // Fall back to base profiles
- pfile_next = this->base_profiles_.get_next ();
+ pfile_next = this->next_forward_profile ();
+ if (pfile_next == 0)
+ {
+ // Fall back to base profiles
+ pfile_next = this->base_profiles_.get_next ();
+ }
+
+ // We may have been forwarded to / from a collocated situation
+ // Check for this and apply / remove optimisation if required.
+ this->orb_core_->reinitialize_object (this);
}
+ else
+ pfile_next = this->base_profiles_.get_next ();
- // We may have been forwarded to / from a collocated situation
- // Check for this and apply / remove optimisation if required.
- this->orb_core_->reinitialize_object (this);
- }
- else
- pfile_next = this->base_profiles_.get_next ();
-
- if (pfile_next == 0)
- this->reset_base ();
- else
- this->set_profile_in_use_i (pfile_next);
+ if (pfile_next == 0)
+ this->reset_base ();
+ else
+ this->set_profile_in_use_i (pfile_next);
- return pfile_next;
+ return pfile_next;
+ }
}
ACE_INLINE TAO_Profile *
diff --git a/TAO/tests/Permanent_Forward/StubTest.cpp b/TAO/tests/Permanent_Forward/StubTest.cpp
index 315eb533c8e..1628637bc82 100755
--- a/TAO/tests/Permanent_Forward/StubTest.cpp
+++ b/TAO/tests/Permanent_Forward/StubTest.cpp
@@ -75,13 +75,10 @@ marshaled_equal_to_other (CORBA::ORB_ptr orb, CORBA::Object_ptr obj, TAO_MProfil
TAO_Stub *stub_copy = obj_copy->_stubobj ();
TAO_MProfile *copy_mprofile = &(stub_copy->base_profiles ());
- TAO_Profile *copy_profile = copy_mprofile->get_profile (0);
- TAO_Profile *other_profile = other_mprofile->get_profile (0);
-
if ( copy_mprofile->size() != other_mprofile->size())
return false;
- for (int i=0; i<copy_mprofile->size(); ++i)
+ for (size_t i=0; i<copy_mprofile->size(); ++i)
{
TAO_Profile *copy_profile = copy_mprofile->get_profile (i);
TAO_Profile *other_profile = other_mprofile->get_profile (i);
@@ -328,13 +325,8 @@ test_forward (CORBA::ORB_ptr orb)
int
main (int argc, char *argv[])
{
- // The variable is declared volatile because, some compilers
- // optimizes this the wrong way. A case is point is the CC compiler
- // on IRIX.
- volatile int Status = 0;
-
ACE_DEBUG ((LM_DEBUG, "---------------------------------------------\n"));
- ACE_DEBUG ((LM_DEBUG, "Running the IORManipulation Tests.\n"));
+ ACE_DEBUG ((LM_DEBUG, "Running the Stub Tests.\n"));
ACE_DECLARE_NEW_CORBA_ENV;
ACE_TRY
@@ -364,17 +356,7 @@ main (int argc, char *argv[])
}
ACE_ENDTRY;
- if (Status == 1)
- {
- // then exception didn't work!
- ACE_DEBUG ((LM_ERROR,
- "**ERROR: Unable to generate the NotFound exception!\n"));
- Status = 0;
- }
- if (Status == 0)
- ACE_DEBUG ((LM_DEBUG, "An ERROR occured during the tests!\n"));
- else
- ACE_DEBUG ((LM_DEBUG, "IORManipulation Tests Successfully Completed!\n"));
+ ACE_DEBUG ((LM_DEBUG, "Stub Tests Successfully Completed!\n"));
ACE_DEBUG ((LM_DEBUG, "---------------------------------------------\n"));
return 0;