summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJohnny Willemsen <jwillemsen@remedy.nl>2008-03-13 09:33:29 +0000
committerJohnny Willemsen <jwillemsen@remedy.nl>2008-03-13 09:33:29 +0000
commitf80b825640d4db43d5c1d1ea2e094a7f4fc8036a (patch)
treec616356ab5fef1d213fe25223cfa40e49ff1fdac
parent35a10c7e3bb2206a1df279255f78856485911686 (diff)
downloadATCD-f80b825640d4db43d5c1d1ea2e094a7f4fc8036a.tar.gz
Thu Mar 13 09:31:57 UTC 2008 Johnny Willemsen <jwillemsen@remedy.nl>
-rw-r--r--TAO/ChangeLog6
-rw-r--r--TAO/tao/PortableServer/Acceptor_Filter_Factory.h1
-rw-r--r--TAO/tao/PortableServer/Root_POA.cpp32
3 files changed, 22 insertions, 17 deletions
diff --git a/TAO/ChangeLog b/TAO/ChangeLog
index 572ba7fcd60..c110461ea45 100644
--- a/TAO/ChangeLog
+++ b/TAO/ChangeLog
@@ -1,3 +1,9 @@
+Thu Mar 13 09:31:57 UTC 2008 Johnny Willemsen <jwillemsen@remedy.nl>
+
+ * tao/PortableServer/Root_POA.cpp:
+ Get the acceptor filter in the constructor and then check it
+ when we need it.
+
Wed Mar 12 13:43:34 UTC 2008 Jonathan Pollack <pollack_j@ociweb.com>
* orbsvcs/orbsvcs/IFRService/IFR_Service_Utils.cpp:
diff --git a/TAO/tao/PortableServer/Acceptor_Filter_Factory.h b/TAO/tao/PortableServer/Acceptor_Filter_Factory.h
index 18a29db0aab..403df664d73 100644
--- a/TAO/tao/PortableServer/Acceptor_Filter_Factory.h
+++ b/TAO/tao/PortableServer/Acceptor_Filter_Factory.h
@@ -58,7 +58,6 @@ public:
/// Static initializer ensures the factory is loaded
static int initialize (void);
-
};
diff --git a/TAO/tao/PortableServer/Root_POA.cpp b/TAO/tao/PortableServer/Root_POA.cpp
index 02932633fa4..dba916db80b 100644
--- a/TAO/tao/PortableServer/Root_POA.cpp
+++ b/TAO/tao/PortableServer/Root_POA.cpp
@@ -205,13 +205,9 @@ TAO_Root_POA::TAO_Root_POA (const TAO_Root_POA::String &name,
ort_adapter_ (0),
adapter_state_ (PortableInterceptor::HOLDING),
network_priority_hook_ (0),
-
#if (TAO_HAS_MINIMUM_POA == 0) && !defined (CORBA_E_COMPACT) && !defined (CORBA_E_MICRO)
-
adapter_activator_ (),
-
#endif /* TAO_HAS_MINIMUM_POA == 0 */
-
children_ (),
lock_ (lock),
orb_core_ (orb_core),
@@ -222,11 +218,9 @@ TAO_Root_POA::TAO_Root_POA (const TAO_Root_POA::String &name,
wait_for_completion_pending_ (0),
waiting_destruction_ (0),
servant_deactivation_condition_ (thread_lock),
-
#if (TAO_HAS_MINIMUM_POA == 0) && !defined (CORBA_E_COMPACT) && !defined (CORBA_E_MICRO)
filter_factory_ (0),
#endif
-
caller_key_to_object_ (0),
servant_for_key_to_object_ (0)
{
@@ -239,6 +233,12 @@ TAO_Root_POA::TAO_Root_POA (const TAO_Root_POA::String &name,
// a cache.
this->cached_policies_.update (this->policies_);
+#if (TAO_HAS_MINIMUM_POA == 0) && !defined (CORBA_E_COMPACT) && !defined (CORBA_E_MICRO)
+ this->filter_factory_
+ = ACE_Dynamic_Service<TAO_Acceptor_Filter_Factory>::instance (
+ "TAO_Acceptor_Filter_Factory");
+#endif
+
this->network_priority_hook_
= ACE_Dynamic_Service<TAO_Network_Priority_Hook>::instance (
"TAO_Network_Priority_Hook");
@@ -2100,17 +2100,17 @@ TAO_Root_POA::key_to_stub_i (const TAO::ObjectKey &key,
TAO_Acceptor_Filter* filter = 0;
#if (TAO_HAS_MINIMUM_POA == 0) && !defined (CORBA_E_COMPACT) && !defined (CORBA_E_MICRO)
- if (this->filter_factory_ == 0)
- this->filter_factory_
- = ACE_Dynamic_Service<TAO_Acceptor_Filter_Factory>::instance ("TAO_Acceptor_Filter_Factory");
-
- filter =
- this->filter_factory_->create_object (this->poa_manager_);
-#else
- ACE_NEW_RETURN (filter,
- TAO_Default_Acceptor_Filter (),
- 0);
+ if (this->filter_factory_)
+ {
+ filter = this->filter_factory_->create_object (this->poa_manager_);
+ }
+ else
#endif
+ {
+ ACE_NEW_RETURN (filter,
+ TAO_Default_Acceptor_Filter (),
+ 0);
+ }
// Give ownership to the auto pointer.
auto_ptr<TAO_Acceptor_Filter> new_filter (filter);