diff options
author | vzykov <vzykov@ae88bc3d-4319-0410-8dbf-d08b4c9d3795> | 2010-05-31 08:42:46 +0000 |
---|---|---|
committer | vzykov <vzykov@ae88bc3d-4319-0410-8dbf-d08b4c9d3795> | 2010-05-31 08:42:46 +0000 |
commit | 79e3897071b4877d2ef4268f0ae35e6c05d51437 (patch) | |
tree | 6ee453af855270e3a6cc10c16cf7d9d17195292f | |
parent | 74b342ee572dba0c00efdf5a396f37731fe645c3 (diff) | |
download | ATCD-79e3897071b4877d2ef4268f0ae35e6c05d51437.tar.gz |
Mon May 31 08:37:17 UTC 2010 Vladimir Zykov <vladimir.zykov@prismtech.com>
* bin/tao_orb_tests.lst:
Marked 2 tests of 3755_Ext as fixed.
* tao/BiDir_GIOP/BiDirGIOP.cpp:
* tao/RTScheduling/RTScheduler_Loader.cpp:
* tao/RTScheduling/RTScheduler_Loader.h:
Fixed bug 3755 in BiDir_GIOP and RTScheduler libraries.
* tao/RTScheduling/RTScheduler_Initializer.cpp:
Changed to use TAO_OBJID_RTCURRENT instead of plain C string.
* tao/RTCORBA/RT_ORB_Loader.cpp:
Rearranged the code so that the loader doesn't redo things
unnecessarily if it's already initialized.
-rw-r--r-- | TAO/ChangeLog | 17 | ||||
-rw-r--r-- | TAO/bin/tao_orb_tests.lst | 4 | ||||
-rw-r--r-- | TAO/tao/BiDir_GIOP/BiDirGIOP.cpp | 22 | ||||
-rw-r--r-- | TAO/tao/RTCORBA/RT_ORB_Loader.cpp | 13 | ||||
-rw-r--r-- | TAO/tao/RTScheduling/RTScheduler_Initializer.cpp | 7 | ||||
-rw-r--r-- | TAO/tao/RTScheduling/RTScheduler_Loader.cpp | 16 | ||||
-rw-r--r-- | TAO/tao/RTScheduling/RTScheduler_Loader.h | 4 |
7 files changed, 64 insertions, 19 deletions
diff --git a/TAO/ChangeLog b/TAO/ChangeLog index ce6b4cbdbb3..da71219f84b 100644 --- a/TAO/ChangeLog +++ b/TAO/ChangeLog @@ -1,3 +1,20 @@ +Mon May 31 08:37:17 UTC 2010 Vladimir Zykov <vladimir.zykov@prismtech.com> + + * bin/tao_orb_tests.lst: + Marked 2 tests of 3755_Ext as fixed. + + * tao/BiDir_GIOP/BiDirGIOP.cpp: + * tao/RTScheduling/RTScheduler_Loader.cpp: + * tao/RTScheduling/RTScheduler_Loader.h: + Fixed bug 3755 in BiDir_GIOP and RTScheduler libraries. + + * tao/RTScheduling/RTScheduler_Initializer.cpp: + Changed to use TAO_OBJID_RTCURRENT instead of plain C string. + + * tao/RTCORBA/RT_ORB_Loader.cpp: + Rearranged the code so that the loader doesn't redo things + unnecessarily if it's already initialized. + Mon May 31 09:04:48 CEST 2010 Johnny Willemsen <jwillemsen@remedy.nl> * TAO version 1.7.9 released. diff --git a/TAO/bin/tao_orb_tests.lst b/TAO/bin/tao_orb_tests.lst index 2db252b5e01..a5a17951d33 100644 --- a/TAO/bin/tao_orb_tests.lst +++ b/TAO/bin/tao_orb_tests.lst @@ -169,8 +169,8 @@ TAO/tests/Bug_3743_Regression/run_test.pl: !NO_IFR TAO/tests/Bug_3746_Regression/run_test.pl: TAO/tests/Bug_3748_Regression/run_test.pl: !MINIMUM !CORBA_E_COMPACT !CORBA_E_MICRO !DISABLE_INTERCEPTORS TAO/tests/Bug_3755_Regression/run_test.pl: !STATIC !CORBA_E_COMPACT !CORBA_E_MICRO !ST -TAO/tests/Bug_3755_Ext_Regression/run_test.pl : !FIXED_BUGS_ONLY !STATIC !LynxOS -TAO/tests/Bug_3755_Ext_Regression/run_test.pl -bidir: !FIXED_BUGS_ONLY !STATIC !MINIMUM !CORBA_E_COMPACT !CORBA_E_MICRO !GIOP10 !DISABLE_BIDIR !LynxOS +TAO/tests/Bug_3755_Ext_Regression/run_test.pl : !STATIC !LynxOS +TAO/tests/Bug_3755_Ext_Regression/run_test.pl -bidir: !STATIC !MINIMUM !CORBA_E_COMPACT !CORBA_E_MICRO !GIOP10 !DISABLE_BIDIR !LynxOS TAO/tests/Bug_3755_Ext_Regression/run_test.pl -messaging: !STATIC !NO_MESSAGING !CORBA_E_MICRO !LynxOS TAO/tests/Bug_3755_Ext_Regression/run_test.pl -csd: !STATIC !ST !CORBA_E_MICRO !LynxOS TAO/tests/Bug_3755_Ext_Regression/run_test.pl -ziop: !STATIC ZIOP ZLIB !LynxOS diff --git a/TAO/tao/BiDir_GIOP/BiDirGIOP.cpp b/TAO/tao/BiDir_GIOP/BiDirGIOP.cpp index ec73e7ce99c..93eeb28ba20 100644 --- a/TAO/tao/BiDir_GIOP/BiDirGIOP.cpp +++ b/TAO/tao/BiDir_GIOP/BiDirGIOP.cpp @@ -24,7 +24,25 @@ TAO_BiDirGIOP_Loader::~TAO_BiDirGIOP_Loader (void) int TAO_BiDirGIOP_Loader::init (int, ACE_TCHAR* []) { - if (!this->initialized_ && TAO_DEF_GIOP_MINOR >= 2) + if (this->initialized_) + return 0; + + this->initialized_ = true; + + ACE_Service_Gestalt *gestalt = ACE_Service_Config::current (); + + ACE_Service_Object * const bidir_loader = + ACE_Dynamic_Service<ACE_Service_Object>::instance ( + gestalt, + "BiDirGIOP_Loader", + true); + + if (bidir_loader != 0 && bidir_loader != this) + { + return bidir_loader->init (0, 0); + } + + if (TAO_DEF_GIOP_MINOR >= 2) { PortableInterceptor::ORBInitializer_ptr tmp_orb_initializer = PortableInterceptor::ORBInitializer::_nil (); @@ -45,8 +63,6 @@ TAO_BiDirGIOP_Loader::init (int, ACE_TCHAR* []) PortableInterceptor::register_orb_initializer ( bidir_orb_initializer.in ()); - - this->initialized_ = true; } catch (const ::CORBA::Exception& ex) { diff --git a/TAO/tao/RTCORBA/RT_ORB_Loader.cpp b/TAO/tao/RTCORBA/RT_ORB_Loader.cpp index 794b1a9e3dc..d9c0abbc250 100644 --- a/TAO/tao/RTCORBA/RT_ORB_Loader.cpp +++ b/TAO/tao/RTCORBA/RT_ORB_Loader.cpp @@ -31,6 +31,12 @@ TAO_RT_ORB_Loader::init (int argc, ACE_TCHAR* argv[]) { ACE_TRACE ("TAO_RT_ORB_Loader::init"); + // Only allow initialization once. + if (this->initialized_) + return 0; + + this->initialized_ = true; + ACE_Service_Gestalt *gestalt = ACE_Service_Config::current (); ACE_Service_Object * const rt_loader = @@ -41,16 +47,9 @@ TAO_RT_ORB_Loader::init (int argc, ACE_TCHAR* argv[]) if (rt_loader != 0 && rt_loader != this) { - this->initialized_ = true; return rt_loader->init (argc, argv); } - // Only allow initialization once. - if (this->initialized_) - return 0; - - this->initialized_ = true; - // Set defaults. int priority_mapping_type = TAO_RT_ORBInitializer::TAO_PRIORITY_MAPPING_DIRECT; diff --git a/TAO/tao/RTScheduling/RTScheduler_Initializer.cpp b/TAO/tao/RTScheduling/RTScheduler_Initializer.cpp index f55f96d11fa..561faff2d0b 100644 --- a/TAO/tao/RTScheduling/RTScheduler_Initializer.cpp +++ b/TAO/tao/RTScheduling/RTScheduler_Initializer.cpp @@ -131,10 +131,11 @@ TAO_RTScheduler_ORB_Initializer::post_init (PortableInterceptor::ORBInitInfo_ptr ACE_DEBUG ((LM_DEBUG, "In post_init\n")); - CORBA::Object_var rt_current_obj = info->resolve_initial_references ("RTCurrent"); + CORBA::Object_var rt_current_obj = + info->resolve_initial_references (TAO_OBJID_RTCURRENT); - - RTCORBA::Current_var rt_current = RTCORBA::Current::_narrow (rt_current_obj.in ()); + RTCORBA::Current_var rt_current = + RTCORBA::Current::_narrow (rt_current_obj.in ()); if (CORBA::is_nil (rt_current.in ())) { diff --git a/TAO/tao/RTScheduling/RTScheduler_Loader.cpp b/TAO/tao/RTScheduling/RTScheduler_Loader.cpp index f34c4b154d1..853674ac95a 100644 --- a/TAO/tao/RTScheduling/RTScheduler_Loader.cpp +++ b/TAO/tao/RTScheduling/RTScheduler_Loader.cpp @@ -37,6 +37,19 @@ TAO_RTScheduler_Loader::init (int, ACE_TCHAR* []) this->initialized_ = true; + ACE_Service_Gestalt *gestalt = ACE_Service_Config::current (); + + ACE_Service_Object * const rts_loader = + ACE_Dynamic_Service<ACE_Service_Object>::instance ( + gestalt, + "RTScheduler_Loader", + true); + + if (rts_loader != 0 && rts_loader != this) + { + return rts_loader->init (0, 0); + } + // Register the ORB initializer. try { @@ -67,8 +80,6 @@ TAO_RTScheduler_Loader::init (int, ACE_TCHAR* []) return 0; } -TAO_END_VERSIONED_NAMESPACE_DECL - ///////////////////////////////////////////////////////////////////// ACE_FACTORY_DEFINE (TAO_RTScheduler, TAO_RTScheduler_Loader) @@ -79,3 +90,4 @@ ACE_STATIC_SVC_DEFINE (TAO_RTScheduler_Loader, ACE_Service_Type::DELETE_THIS | ACE_Service_Type::DELETE_OBJ, 0) +TAO_END_VERSIONED_NAMESPACE_DECL diff --git a/TAO/tao/RTScheduling/RTScheduler_Loader.h b/TAO/tao/RTScheduling/RTScheduler_Loader.h index 78b9d9bc7ae..47021c59f02 100644 --- a/TAO/tao/RTScheduling/RTScheduler_Loader.h +++ b/TAO/tao/RTScheduling/RTScheduler_Loader.h @@ -47,10 +47,10 @@ private: bool initialized_; }; -TAO_END_VERSIONED_NAMESPACE_DECL - ACE_STATIC_SVC_DECLARE_EXPORT (TAO_RTScheduler, TAO_RTScheduler_Loader) ACE_FACTORY_DECLARE (TAO_RTScheduler, TAO_RTScheduler_Loader) +TAO_END_VERSIONED_NAMESPACE_DECL + #include /**/ "ace/post.h" #endif /* TAO_RTSCHEDULER_LOADER_H */ |