summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPhil Mesnier <mesnier_p@ociweb.com>2006-04-26 16:42:12 +0000
committerPhil Mesnier <mesnier_p@ociweb.com>2006-04-26 16:42:12 +0000
commit4274f7f32351550bc6b3f8b346488f1b0a993bb4 (patch)
tree5c16b178ae7708f1fa01a1f1835bd96462d3eaba
parent04977ca2ac0dc30f28e5da4063fbeb38f1d11e91 (diff)
downloadATCD-4274f7f32351550bc6b3f8b346488f1b0a993bb4.tar.gz
ChangeLog tag: Wed Apr 26 16:30:56 UTC 2006 Phil Mesnier <mesnier_p@ociweb.com>
-rw-r--r--TAO/ChangeLog19
-rw-r--r--TAO/tao/PortableServer/POAManagerFactory.cpp25
2 files changed, 30 insertions, 14 deletions
diff --git a/TAO/ChangeLog b/TAO/ChangeLog
index 037b195e513..3536cc3b41e 100644
--- a/TAO/ChangeLog
+++ b/TAO/ChangeLog
@@ -1,3 +1,9 @@
+Wed Apr 26 16:30:56 UTC 2006 Phil Mesnier <mesnier_p@ociweb.com>
+
+ * tao/PortableServer/POAManagerFactory.cpp:
+
+ Correct a bug found by the Borland compiler.
+
Wed Apr 26 13:47:28 UTC 2006 Phil Mesnier <mesnier_p@ociweb.com>
* tao/EndpointPolicy.mpc:
@@ -35,11 +41,14 @@ Wed Apr 26 13:47:28 UTC 2006 Phil Mesnier <mesnier_p@ociweb.com>
* tao/EndpointPolicy/IIOPEndpointValue_i.cpp:
The EndpointPolicy is a new, TAO-specific policy that is applied
- to POAManagers via the POAManagerFactory. The Endpoint policy
- acts as a filter for constraining the final endpoints or
- profiles listed in an IOR when it is created by a POA associated
- with the POAManager containing the policy. The EndpointPolicy
- value is a sequence, allow multiple endpoints to be published.
+ to POAManagers via the POAManagerFactory. This commit resolves
+ Bugzilla bug #2484.
+
+ The Endpoint policy acts as a filter for constraining the final
+ endpoints or profiles listed in an IOR when it is created by a
+ POA associated with the POAManager containing the policy. The
+ EndpointPolicy value is a sequence, allow multiple endpoints to
+ be published.
The way this works is that the ORB is initialized with all the
-ORBEndpoint options it needs to provide access to all the
diff --git a/TAO/tao/PortableServer/POAManagerFactory.cpp b/TAO/tao/PortableServer/POAManagerFactory.cpp
index 4547d162af2..3a697f1bdb6 100644
--- a/TAO/tao/PortableServer/POAManagerFactory.cpp
+++ b/TAO/tao/PortableServer/POAManagerFactory.cpp
@@ -42,13 +42,15 @@ TAO_POAManager_Factory::create_POAManager (
::CORBA::PolicyError))
{
if (policies.length () > 1
- || (policies.length () == 1 && policies[0]->policy_type () != EndpointPolicy::ENDPOINT_POLICY_TYPE))
+ || (policies.length () == 1 &&
+ policies[0]->policy_type () != EndpointPolicy::ENDPOINT_POLICY_TYPE))
{
ACE_THROW_RETURN (CORBA::PolicyError (CORBA::BAD_POLICY),
::PortableServer::POAManager::_nil ());
}
- PortableServer::POAManager_var poamanager = PortableServer::POAManager::_nil ();
+ PortableServer::POAManager_var poamanager =
+ PortableServer::POAManager::_nil ();
if (id != 0)
{
poamanager = this->find (id ACE_ENV_ARG_PARAMETER);
@@ -63,13 +65,18 @@ TAO_POAManager_Factory::create_POAManager (
}
}
- ACE_NEW_THROW_EX (poamanager,
- TAO_POA_Manager (object_adapter_, id, policies, this),
- CORBA::NO_MEMORY (
- CORBA::SystemException::_tao_minor_code (0,
- ENOMEM),
- CORBA::COMPLETED_NO));
- ACE_CHECK_RETURN (::PortableServer::POAManager::_nil ());
+ // this indirection brought to you by borland's compiler and its refusal
+ // to directly assign the newly crated TAO_POA_Manager to a POAManager_var.
+ {
+ PortableServer::POAManager_ptr pm = 0;
+ ACE_NEW_THROW_EX (pm,
+ TAO_POA_Manager (object_adapter_, id, policies, this),
+ CORBA::NO_MEMORY
+ (CORBA::SystemException::_tao_minor_code (0, ENOMEM),
+ CORBA::COMPLETED_NO));
+ ACE_CHECK_RETURN (::PortableServer::POAManager::_nil ());
+ poamanager = pm;
+ }
this->register_poamanager (poamanager.in ());