diff options
author | Ossama Othman <ossama-othman@users.noreply.github.com> | 2001-04-09 23:41:37 +0000 |
---|---|---|
committer | Ossama Othman <ossama-othman@users.noreply.github.com> | 2001-04-09 23:41:37 +0000 |
commit | b8c65bb8f0d8303826e6d1636694ec13b6b9b979 (patch) | |
tree | 749856a747c3e3d34c3f64cb9b3c4e3c58b1dd1a /TAO/tao/ORBInitInfo.cpp | |
parent | 429990d09e8b5ef63d2ea818acab48eb2279a495 (diff) | |
download | ATCD-b8c65bb8f0d8303826e6d1636694ec13b6b9b979.tar.gz |
ChangeLogTag:Mon Apr 9 16:40:24 2001 Ossama Othman <ossama@uci.edu>
Diffstat (limited to 'TAO/tao/ORBInitInfo.cpp')
-rw-r--r-- | TAO/tao/ORBInitInfo.cpp | 23 |
1 files changed, 17 insertions, 6 deletions
diff --git a/TAO/tao/ORBInitInfo.cpp b/TAO/tao/ORBInitInfo.cpp index 53986960f1d..6fbbaeabd86 100644 --- a/TAO/tao/ORBInitInfo.cpp +++ b/TAO/tao/ORBInitInfo.cpp @@ -90,6 +90,17 @@ TAO_ORBInitInfo::register_initial_reference ( this->check_validity (ACE_TRY_ENV); ACE_CHECK; + // This method is only valid during pre_init(), i.e. only before + // TAO_ORB_Core::init() has been called. The ORB Core starts out + // in the "shutdown" state, so checking if it is in that state + // would indicate that the ORB hasn't been initalized yet, at least + // partially, meaning that initial reference registration can + // proceed. + if (!(this->orb_core_->has_shutdown ())) + ACE_THROW (CORBA::BAD_INV_ORDER ()); // @@ Throw an exception? + // What about the minor + // code? + if (id == 0) ACE_THROW (PortableInterceptor::ORBInitInfo::InvalidName ()); else if (ACE_OS_String::strlen (id) == 0) @@ -112,11 +123,11 @@ TAO_ORBInitInfo::resolve_initial_references ( this->check_validity (ACE_TRY_ENV); ACE_CHECK_RETURN (CORBA::Object::_nil ()); - /// This method is only valid during post_init(), i.e. only after - /// TAO_ORB_Core::init() has been called. The ORB Core starts out - /// in the "shutdown" state, so checking if it is in that state - /// would indicate that the ORB hasn't been initalized yet, at least - /// partially. + // This method is only valid during post_init(), i.e. only after + // TAO_ORB_Core::init() has been called. The ORB Core starts out + // in the "shutdown" state, so checking if it is in that state + // would indicate that the ORB hasn't been initalized yet, at least + // partially. this->orb_core_->check_shutdown (ACE_TRY_ENV); ACE_CHECK_RETURN (CORBA::Object::_nil ()); @@ -307,7 +318,7 @@ TAO_ORBInitInfo::_tao_QueryInterface (ptr_arith_t type) else if (type == ACE_reinterpret_cast (ptr_arith_t, &CORBA::Object::_narrow)) retv = ACE_reinterpret_cast (void *, ACE_static_cast (CORBA::Object_ptr, this)); - + // if (retv) // this->_add_ref (); return retv; |