summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJohnny Willemsen <jwillemsen@remedy.nl>2007-02-06 16:34:57 +0000
committerJohnny Willemsen <jwillemsen@remedy.nl>2007-02-06 16:34:57 +0000
commit5953eda0ba7f8a659f96c14949eaebc913c312ac (patch)
tree51c09f93a23b19693872d94e4f1cf121f1ff9de8
parent63b4d0d6a202f98a63a10eda2c57293e00f80efd (diff)
downloadATCD-5953eda0ba7f8a659f96c14949eaebc913c312ac.tar.gz
Tue Feb 6 16:33:14 UTC 2007 Johnny Willemsen <jwillemsen@remedy.nl>
-rw-r--r--TAO/ChangeLog54
-rw-r--r--TAO/tao/Collocated_Invocation.cpp36
-rw-r--r--TAO/tao/DynamicInterface/DII_Arguments.cpp10
-rw-r--r--TAO/tao/DynamicInterface/DII_Arguments.inl5
-rw-r--r--TAO/tao/DynamicInterface/DII_Invocation_Adapter.cpp23
-rw-r--r--TAO/tao/DynamicInterface/DII_Reply_Dispatcher.cpp8
-rw-r--r--TAO/tao/Exception.h15
-rw-r--r--TAO/tao/GIOP_Message_Generator_Parser_10.cpp12
-rw-r--r--TAO/tao/GIOP_Message_State.cpp4
-rw-r--r--TAO/tao/GIOP_Message_State.inl22
-rw-r--r--TAO/tao/GIOP_Message_Version.inl11
-rw-r--r--TAO/tao/IORInterceptor_Adapter.h2
-rw-r--r--TAO/tao/IORInterceptor_Adapter_Factory.h4
-rw-r--r--TAO/tao/IOR_Parser.h3
-rw-r--r--TAO/tao/Invocation_Base.cpp20
-rw-r--r--TAO/tao/Invocation_Endpoint_Selectors.cpp20
-rw-r--r--TAO/tao/Invocation_Endpoint_Selectors.h6
-rw-r--r--TAO/tao/LocateRequest_Invocation.cpp11
-rw-r--r--TAO/tao/LocateRequest_Invocation_Adapter.cpp19
-rw-r--r--TAO/tao/MCAST_Parser.cpp3
-rw-r--r--TAO/tao/ObjectKey_Table.cpp3
-rw-r--r--TAO/tao/Object_Ref_Table.cpp3
-rw-r--r--TAO/tao/Object_Ref_Table.inl3
-rw-r--r--TAO/tao/Object_T.cpp4
-rw-r--r--TAO/tao/RTScheduling/Request_Interceptor.cpp11
-rw-r--r--TAO/tao/Strategies/SCIOP_Endpoint.cpp5
-rw-r--r--TAO/tao/Strategies/SCIOP_Factory.cpp3
-rw-r--r--TAO/tao/Strategies/SCIOP_Transport.cpp12
-rw-r--r--TAO/tao/Strategies/SHMIOP_Acceptor.cpp18
-rw-r--r--TAO/tao/Strategies/SHMIOP_Transport.cpp15
-rw-r--r--TAO/tao/Strategies/SHMIOP_Transport.h3
-rw-r--r--TAO/tao/Strategies/UIOP_Transport.cpp18
-rw-r--r--TAO/tao/TransportCurrent/Current_ORBInitializer.h7
-rw-r--r--TAO/tao/TransportCurrent/Current_ORBInitializer_Base.h3
-rw-r--r--TAO/tao/Valuetype/AbstractBase.cpp5
-rw-r--r--TAO/tao/Valuetype/ValueBase.cpp14
-rw-r--r--TAO/tao/Valuetype/ValueFactory.cpp2
-rw-r--r--TAO/tao/Valuetype/ValueFactory_Map.cpp7
-rw-r--r--TAO/tao/operation_details.cpp13
-rw-r--r--TAO/tao/operation_details.h9
-rw-r--r--TAO/tao/operation_details.inl1
41 files changed, 206 insertions, 241 deletions
diff --git a/TAO/ChangeLog b/TAO/ChangeLog
index e39d84bd02d..2f7a3d4b591 100644
--- a/TAO/ChangeLog
+++ b/TAO/ChangeLog
@@ -1,3 +1,57 @@
+Tue Feb 6 16:33:14 UTC 2007 Johnny Willemsen <jwillemsen@remedy.nl>
+
+ * tao/Collocated_Invocation.cpp:
+ Added a check that we don't rethrow an user exception that is
+ not in the signature list, if that is the case we throw
+ an unknown. Fixes bugzilla 2064
+
+ * tao/operation_details.cpp
+ * tao/operation_details.h
+ * tao/operation_details.inl
+ Added support to check whether an exception is in the list of
+ exceptions for this operation
+
+ * tao/Invocation_Base.cpp:
+ Some more changes related to removing ACE_THROW_SPEC
+
+ * tao/DynamicInterface/DII_Arguments.cpp
+ * tao/DynamicInterface/DII_Arguments.inl
+ * tao/DynamicInterface/DII_Invocation_Adapter.cpp
+ * tao/DynamicInterface/DII_Reply_Dispatcher.cpp
+ * tao/Exception.h
+ * tao/GIOP_Message_Generator_Parser_10.cpp
+ * tao/GIOP_Message_State.cpp
+ * tao/GIOP_Message_State.inl
+ * tao/GIOP_Message_Version.inl
+ * tao/Invocation_Endpoint_Selectors.cpp
+ * tao/Invocation_Endpoint_Selectors.h
+ * tao/IOR_Parser.h
+ * tao/IORInterceptor_Adapter.h
+ * tao/IORInterceptor_Adapter_Factory.h
+ * tao/LocateRequest_Invocation.cpp
+ * tao/LocateRequest_Invocation_Adapter.cpp
+ * tao/MCAST_Parser.cpp
+ * tao/Object.cpp
+ * tao/Object_Ref_Table.cpp
+ * tao/Object_Ref_Table.inl
+ * tao/Object_T.cpp
+ * tao/ObjectKey_Table.cpp
+ * tao/RTScheduling/Request_Interceptor.cpp
+ * tao/Strategies/SCIOP_Endpoint.cpp
+ * tao/Strategies/SCIOP_Factory.cpp
+ * tao/Strategies/SCIOP_Transport.cpp
+ * tao/Strategies/SHMIOP_Acceptor.cpp
+ * tao/Strategies/SHMIOP_Transport.cpp
+ * tao/Strategies/SHMIOP_Transport.h
+ * tao/Strategies/UIOP_Transport.cpp
+ * tao/TransportCurrent/Current_ORBInitializer.h
+ * tao/TransportCurrent/Current_ORBInitializer_Base.h
+ * tao/Valuetype/AbstractBase.cpp
+ * tao/Valuetype/ValueBase.cpp
+ * tao/Valuetype/ValueFactory.cpp
+ * tao/Valuetype/ValueFactory_Map.cpp
+ Layout changes
+
Mon Feb 5 23:30:42 UTC 2007 Jeff Parsons <j.parsons@vanderbilt.edu>
* TAO_IDL/be/be_visitor_sequence/sequence_ch.cpp:
diff --git a/TAO/tao/Collocated_Invocation.cpp b/TAO/tao/Collocated_Invocation.cpp
index 157a3fae6c5..eb3b6eaaba3 100644
--- a/TAO/tao/Collocated_Invocation.cpp
+++ b/TAO/tao/Collocated_Invocation.cpp
@@ -42,8 +42,7 @@ namespace TAO
/// Start the interception point
#if TAO_HAS_INTERCEPTORS == 1
- s =
- this->send_request_interception ();
+ s = this->send_request_interception ();
if (s != TAO_INVOKE_SUCCESS)
return s;
@@ -110,7 +109,35 @@ namespace TAO
return s;
#endif /*TAO_HAS_INTERCEPTORS */
}
- catch ( ::CORBA::Exception& ex)
+ catch ( ::CORBA::UserException& ex)
+ {
+ // Ignore CORBA exceptions for oneways
+ if (this->response_expected_ == false)
+ return TAO_INVOKE_SUCCESS;
+
+#if TAO_HAS_INTERCEPTORS == 1
+ PortableInterceptor::ReplyStatus const status =
+ this->handle_any_exception (&ex);
+
+ if (status == PortableInterceptor::LOCATION_FORWARD ||
+ status == PortableInterceptor::TRANSPORT_RETRY)
+ s = TAO_INVOKE_RESTART;
+ else
+#endif /* TAO_HAS_INTERCEPTORS */
+ {
+ // Check whether the user exception thrown matches the signature
+ // list, if not, then throw an Unknown exception
+ if (!this->details_.has_exception (ex))
+ {
+ throw ::CORBA::UNKNOWN (0, CORBA::COMPLETED_YES);
+ }
+ else
+ {
+ throw;
+ }
+ }
+ }
+ catch ( ::CORBA::SystemException& TAO_INTERCEPTOR (ex))
{
// Ignore CORBA exceptions for oneways
if (this->response_expected_ == false)
@@ -124,8 +151,6 @@ namespace TAO
status == PortableInterceptor::TRANSPORT_RETRY)
s = TAO_INVOKE_RESTART;
else
-#else
- ACE_UNUSED_ARG (ex);
#endif /* TAO_HAS_INTERCEPTORS */
throw;
}
@@ -134,7 +159,6 @@ namespace TAO
{
// Notify interceptors of non-CORBA exception, and propagate
// that exception to the caller.
-
PortableInterceptor::ReplyStatus const st =
this->handle_all_exception ();
diff --git a/TAO/tao/DynamicInterface/DII_Arguments.cpp b/TAO/tao/DynamicInterface/DII_Arguments.cpp
index fc433181a84..881bb69bfb6 100644
--- a/TAO/tao/DynamicInterface/DII_Arguments.cpp
+++ b/TAO/tao/DynamicInterface/DII_Arguments.cpp
@@ -28,8 +28,7 @@ namespace TAO
{
if (this->x_ !=0 && this->x_->value ()->impl ())
{
- this->x_->value ()->impl ()->_tao_decode (cdr
- );
+ this->x_->value ()->impl ()->_tao_decode (cdr);
}
}
catch (const ::CORBA::Exception&)
@@ -55,9 +54,7 @@ namespace TAO
{
try
{
- this->x_->_tao_encode (cdr,
- CORBA::ARG_IN | CORBA::ARG_INOUT
- );
+ this->x_->_tao_encode (cdr, CORBA::ARG_IN | CORBA::ARG_INOUT);
}
catch (const ::CORBA::Exception&)
{
@@ -104,8 +101,7 @@ namespace TAO
if (!this->x_->item (i)->value ())
return;
- (*lst)[i].argument.replace (
- this->x_->item (i)->value ()->impl ());
+ (*lst)[i].argument.replace (this->x_->item (i)->value ()->impl ());
switch (this->x_->item (i)->flags ())
{
diff --git a/TAO/tao/DynamicInterface/DII_Arguments.inl b/TAO/tao/DynamicInterface/DII_Arguments.inl
index 5acf60d6876..c8a05b4183a 100644
--- a/TAO/tao/DynamicInterface/DII_Arguments.inl
+++ b/TAO/tao/DynamicInterface/DII_Arguments.inl
@@ -22,15 +22,14 @@ namespace TAO
// ===================================================================
ACE_INLINE
- NVList_Argument::NVList_Argument (CORBA::NVList_ptr x,
- bool lazy_eval)
+ NVList_Argument::NVList_Argument (CORBA::NVList_ptr x, bool lazy_eval)
: x_ (x)
, lazy_evaluation_ (lazy_eval)
{
}
ACE_INLINE
- CORBA::NVList_ptr
+ CORBA::NVList_ptr
NVList_Argument::arg () const
{
return this->x_;
diff --git a/TAO/tao/DynamicInterface/DII_Invocation_Adapter.cpp b/TAO/tao/DynamicInterface/DII_Invocation_Adapter.cpp
index 6410af28345..46b6a662470 100644
--- a/TAO/tao/DynamicInterface/DII_Invocation_Adapter.cpp
+++ b/TAO/tao/DynamicInterface/DII_Invocation_Adapter.cpp
@@ -78,8 +78,7 @@ namespace TAO
);
- if (status == TAO_INVOKE_RESTART &&
- synch.is_forwarded ())
+ if (status == TAO_INVOKE_RESTART && synch.is_forwarded ())
{
effective_target =
synch.steal_forwarded_reference ();
@@ -92,8 +91,7 @@ namespace TAO
#endif
this->object_forwarded (effective_target,
r.stub (),
- permanent_forward
- );
+ permanent_forward);
}
return status;
}
@@ -127,8 +125,7 @@ namespace TAO
void
DII_Deferred_Invocation_Adapter::invoke (
TAO::Exception_Data *ex,
- unsigned long ex_count
- )
+ unsigned long ex_count)
{
// New reply dispatcher on the heap, because we will go out of
// scope and hand over the reply dispatcher to the ORB.
@@ -139,9 +136,7 @@ namespace TAO
this->orb_core_),
CORBA::NO_MEMORY ());
- Invocation_Adapter::invoke (ex,
- ex_count
- );
+ Invocation_Adapter::invoke (ex, ex_count);
}
Invocation_Status
@@ -149,8 +144,7 @@ namespace TAO
TAO_Operation_Details &op,
CORBA::Object_var &effective_target,
Profile_Transport_Resolver &r,
- ACE_Time_Value *&max_wait_time
- )
+ ACE_Time_Value *&max_wait_time)
{
// Simple sanity check
if (this->mode_ != TAO_DII_DEFERRED_INVOCATION ||
@@ -173,14 +167,11 @@ namespace TAO
r.transport ()->messaging_object ()->out_stream ().reset_byte_order (request_->_tao_byte_order ());
- Invocation_Status status =
- synch.remote_invocation (max_wait_time
- );
+ Invocation_Status status = synch.remote_invocation (max_wait_time);
if (status == TAO_INVOKE_RESTART)
{
- effective_target =
- synch.steal_forwarded_reference ();
+ effective_target = synch.steal_forwarded_reference ();
}
return status;
diff --git a/TAO/tao/DynamicInterface/DII_Reply_Dispatcher.cpp b/TAO/tao/DynamicInterface/DII_Reply_Dispatcher.cpp
index fe5965ab095..6c209a2c955 100644
--- a/TAO/tao/DynamicInterface/DII_Reply_Dispatcher.cpp
+++ b/TAO/tao/DynamicInterface/DII_Reply_Dispatcher.cpp
@@ -41,9 +41,7 @@ TAO_DII_Deferred_Reply_Dispatcher::dispatch_reply (
this->reply_status_ = params.reply_status_;
// Transfer the <params.input_cdr_>'s content to this->reply_cdr_
- ACE_Data_Block *db =
- this->reply_cdr_.clone_from (*params.input_cdr_);
-
+ ACE_Data_Block *db = this->reply_cdr_.clone_from (*params.input_cdr_);
if (db == 0)
{
@@ -82,9 +80,7 @@ TAO_DII_Deferred_Reply_Dispatcher::dispatch_reply (
try
{
// Call the Request back and send the reply data.
- this->req_->handle_response (this->reply_cdr_,
- this->reply_status_
- );
+ this->req_->handle_response (this->reply_cdr_, this->reply_status_);
}
catch (const ::CORBA::Exception& ex)
{
diff --git a/TAO/tao/Exception.h b/TAO/tao/Exception.h
index 5362927702f..e4ee529106f 100644
--- a/TAO/tao/Exception.h
+++ b/TAO/tao/Exception.h
@@ -133,27 +133,23 @@ namespace CORBA
/**
* @note This method is TAO-specific.
*/
- void _tao_print_exception (const char *info,
- FILE *f = stdout) const;
+ void _tao_print_exception (const char *info, FILE *f = stdout) const;
#if defined (ACE_USES_WCHAR)
/// ACE_WCHAR_T version of _tao_print_exception.
/**
* @note This method is TAO-specific.
*/
- void _tao_print_exception (const ACE_WCHAR_T *info,
- FILE *f = stdout) const;
+ void _tao_print_exception (const ACE_WCHAR_T *info, FILE *f = stdout) const;
#endif // ACE_USES_WCHAR
/// Returns a string containing information about the exception. This
/// function is not CORBA compliant.
virtual ACE_CString _info (void) const = 0;
- virtual void _tao_encode (TAO_OutputCDR &cdr
- ) const = 0;
+ virtual void _tao_encode (TAO_OutputCDR &cdr) const = 0;
- virtual void _tao_decode (TAO_InputCDR &cdr
- ) = 0;
+ virtual void _tao_decode (TAO_InputCDR &cdr) = 0;
/// Used in the non-copying Any insertion operator.
static void _tao_any_destructor (void *);
@@ -192,8 +188,7 @@ namespace CORBA
Exception & operator = (const Exception & src);
/// Construct from a respository id.
- Exception (const char *repository_id,
- const char *local_name);
+ Exception (const char *repository_id, const char *local_name);
private:
diff --git a/TAO/tao/GIOP_Message_Generator_Parser_10.cpp b/TAO/tao/GIOP_Message_Generator_Parser_10.cpp
index 72332bd3ac6..76dc07c84e4 100644
--- a/TAO/tao/GIOP_Message_Generator_Parser_10.cpp
+++ b/TAO/tao/GIOP_Message_Generator_Parser_10.cpp
@@ -63,8 +63,7 @@ TAO_GIOP_Message_Generator_Parser_10::write_request_header (
return false;
}
- msg.write_string (opdetails.opname_len (),
- opdetails.opname ());
+ msg.write_string (opdetails.opname_len (), opdetails.opname ());
// Last element of request header is the principal; no portable way
// to get it, we just pass empty principal (convention: indicates
@@ -410,8 +409,7 @@ TAO_GIOP_Message_Generator_Parser_10::parse_request_header (
int
TAO_GIOP_Message_Generator_Parser_10::parse_locate_header (
- TAO_GIOP_Locate_Request_Header &request
- )
+ TAO_GIOP_Locate_Request_Header &request)
{
// Get the stream
TAO_InputCDR &msg = request.incoming_stream ();
@@ -426,8 +424,7 @@ TAO_GIOP_Message_Generator_Parser_10::parse_locate_header (
request.request_id (req_id);
// Get the object key
- hdr_status =
- hdr_status && request.profile ().unmarshall_object_key (msg);
+ hdr_status = hdr_status && request.profile ().unmarshall_object_key (msg);
return hdr_status ? 0 : -1;
}
@@ -464,8 +461,7 @@ TAO_GIOP_Message_Generator_Parser_10::parse_reply (
int
TAO_GIOP_Message_Generator_Parser_10::parse_locate_reply (
TAO_InputCDR &cdr,
- TAO_Pluggable_Reply_Params &params
- )
+ TAO_Pluggable_Reply_Params &params)
{
if (TAO_GIOP_Message_Generator_Parser::parse_locate_reply (cdr,
params) == -1)
diff --git a/TAO/tao/GIOP_Message_State.cpp b/TAO/tao/GIOP_Message_State.cpp
index 55799ea5dcf..1d19bfbb7ce 100644
--- a/TAO/tao/GIOP_Message_State.cpp
+++ b/TAO/tao/GIOP_Message_State.cpp
@@ -27,7 +27,6 @@ TAO_GIOP_Message_State::TAO_GIOP_Message_State (void)
{
}
-
int
TAO_GIOP_Message_State::parse_message_header (ACE_Message_Block &incoming)
{
@@ -103,9 +102,6 @@ TAO_GIOP_Message_State::parse_message_header_i (ACE_Message_Block &incoming)
return 0; // success
}
-
-
-
int
TAO_GIOP_Message_State::parse_magic_bytes (char *buf)
{
diff --git a/TAO/tao/GIOP_Message_State.inl b/TAO/tao/GIOP_Message_State.inl
index 2de1bbb2b03..a91d573d232 100644
--- a/TAO/tao/GIOP_Message_State.inl
+++ b/TAO/tao/GIOP_Message_State.inl
@@ -10,7 +10,7 @@ TAO_GIOP_Message_State::message_size (void) const
CORBA::ULong len =
this->message_size_ + TAO_GIOP_MESSAGE_HEADER_LEN;
- return len;
+ return len;
}
ACE_INLINE CORBA::ULong
@@ -34,24 +34,4 @@ TAO_GIOP_Message_State::reset (void)
this->missing_data_ = 0;
}
-#if 0
-ACE_INLINE int
-TAO_GIOP_Message_State::message_fragmented (void)
-{
- if (this->more_fragments)
- return 1;
-
- return 0;
-}
-
-
-
-ACE_INLINE CORBA::Boolean
-TAO_GIOP_Message_State::header_received (void) const
-{
- return this->message_size != 0;
-}
-
-#endif
-
TAO_END_VERSIONED_NAMESPACE_DECL
diff --git a/TAO/tao/GIOP_Message_Version.inl b/TAO/tao/GIOP_Message_Version.inl
index 6328534b3fc..941389650c1 100644
--- a/TAO/tao/GIOP_Message_Version.inl
+++ b/TAO/tao/GIOP_Message_Version.inl
@@ -21,8 +21,7 @@ TAO_GIOP_Message_Version::TAO_GIOP_Message_Version (CORBA::Octet maj,
}
ACE_INLINE TAO_GIOP_Message_Version &
-TAO_GIOP_Message_Version::operator= (
- const TAO_GIOP_Message_Version &src)
+TAO_GIOP_Message_Version::operator= (const TAO_GIOP_Message_Version &src)
{
if (this != &src)
{
@@ -35,18 +34,16 @@ TAO_GIOP_Message_Version::operator= (
ACE_INLINE void
-TAO_GIOP_Message_Version::set_version (CORBA::Octet maj,
- CORBA::Octet min)
+TAO_GIOP_Message_Version::set_version (CORBA::Octet maj, CORBA::Octet min)
{
this->major = maj;
this->minor = min;
}
ACE_INLINE bool
-TAO_GIOP_Message_Version::operator== (
- const TAO_GIOP_Message_Version &src)
+TAO_GIOP_Message_Version::operator== (const TAO_GIOP_Message_Version &src)
{
- return this->major == src.major && this->minor == src.minor;
+ return this->minor == src.minor && this->major == src.major;
}
ACE_INLINE bool
diff --git a/TAO/tao/IORInterceptor_Adapter.h b/TAO/tao/IORInterceptor_Adapter.h
index 91e5ab57b63..3df2602431e 100644
--- a/TAO/tao/IORInterceptor_Adapter.h
+++ b/TAO/tao/IORInterceptor_Adapter.h
@@ -80,7 +80,7 @@ public:
* IORInterceptor::components_established() once the former is
* completed.
*/
- virtual void establish_components (TAO_Root_POA *poa )
+ virtual void establish_components (TAO_Root_POA *poa)
ACE_THROW_SPEC ((CORBA::SystemException)) = 0;
/// Call the IORInterceptor::components_established() method on all
diff --git a/TAO/tao/IORInterceptor_Adapter_Factory.h b/TAO/tao/IORInterceptor_Adapter_Factory.h
index 87f6fc0057e..34c70a02360 100644
--- a/TAO/tao/IORInterceptor_Adapter_Factory.h
+++ b/TAO/tao/IORInterceptor_Adapter_Factory.h
@@ -42,9 +42,7 @@ class TAO_Export TAO_IORInterceptor_Adapter_Factory
public:
virtual ~TAO_IORInterceptor_Adapter_Factory (void);
- virtual TAO_IORInterceptor_Adapter * create (
-
- )
+ virtual TAO_IORInterceptor_Adapter * create (void)
ACE_THROW_SPEC ((CORBA::SystemException)) = 0;
};
diff --git a/TAO/tao/IOR_Parser.h b/TAO/tao/IOR_Parser.h
index 4dffe43fa50..c53c0594e36 100644
--- a/TAO/tao/IOR_Parser.h
+++ b/TAO/tao/IOR_Parser.h
@@ -59,8 +59,7 @@ public:
* The call may raise the standard system exceptions (NO_MEMORY,
* INV_OBJREF, etc.)
*/
- virtual CORBA::Object_ptr parse_string (const char *ior,
- CORBA::ORB_ptr orb)
+ virtual CORBA::Object_ptr parse_string (const char *ior, CORBA::ORB_ptr orb)
ACE_THROW_SPEC ((CORBA::SystemException)) = 0;
};
diff --git a/TAO/tao/Invocation_Base.cpp b/TAO/tao/Invocation_Base.cpp
index eefdf4a6456..85b35de3d62 100644
--- a/TAO/tao/Invocation_Base.cpp
+++ b/TAO/tao/Invocation_Base.cpp
@@ -91,13 +91,17 @@ namespace TAO
{
try
{
+ // This is a begin interception point
this->adapter_->send_request (*this);
}
catch ( ::CORBA::Exception& ex)
{
(void) this->handle_any_exception (&ex);
-
- // This is a begin interception point
+ throw;
+ }
+ catch (...)
+ {
+ (void) this->handle_all_exception ();
throw;
}
@@ -122,7 +126,11 @@ namespace TAO
catch ( ::CORBA::Exception& ex)
{
(void) this->handle_any_exception (&ex);
-
+ throw;
+ }
+ catch (...)
+ {
+ (void) this->handle_all_exception ();
throw;
}
@@ -194,8 +202,7 @@ namespace TAO
PortableInterceptor::ReplyStatus
Invocation_Base::handle_all_exception (void)
{
- CORBA::UNKNOWN ex;
- this->exception (&ex);
+ this->exception (&unknown_exception);
PortableInterceptor::ReplyStatus status =
PortableInterceptor::SYSTEM_EXCEPTION;
@@ -204,8 +211,7 @@ namespace TAO
{
this->adapter_->receive_exception (*this);
- status =
- this->adapter_->reply_status (*this);
+ status = this->adapter_->reply_status (*this);
}
return status;
diff --git a/TAO/tao/Invocation_Endpoint_Selectors.cpp b/TAO/tao/Invocation_Endpoint_Selectors.cpp
index 3a6981e5a2b..c47fe1a5fa1 100644
--- a/TAO/tao/Invocation_Endpoint_Selectors.cpp
+++ b/TAO/tao/Invocation_Endpoint_Selectors.cpp
@@ -28,8 +28,7 @@ TAO_Default_Endpoint_Selector::~TAO_Default_Endpoint_Selector (void)
void
TAO_Default_Endpoint_Selector::select_endpoint (TAO::Profile_Transport_Resolver *r,
- ACE_Time_Value *max_wait_time
- )
+ ACE_Time_Value *max_wait_time)
{
do
{
@@ -45,18 +44,12 @@ TAO_Default_Endpoint_Selector::select_endpoint (TAO::Profile_Transport_Resolver
if (r->profile ()->endpoint_count () > 1 &&
r->use_parallel_connect())
{
-
- TAO_Endpoint *ep =
- r->profile ()->endpoint ();
+ TAO_Endpoint *ep = r->profile ()->endpoint ();
TAO_Base_Transport_Property desc (ep);
- bool success =
- r->try_parallel_connect (&desc,
- max_wait_time
- );
// Check if the connect has completed.
- if (success)
+ if (r->try_parallel_connect (&desc, max_wait_time))
return;
// The default implementation of try_parallel_connect returns
// a not supported errno. In this case, allow the ordinary
@@ -72,13 +65,9 @@ TAO_Default_Endpoint_Selector::select_endpoint (TAO::Profile_Transport_Resolver
ep = r->profile ()->next_filtered_endpoint (ep))
{
TAO_Base_Transport_Property desc (ep);
- bool retval =
- r->try_connect (&desc,
- max_wait_time
- );
// Check if the connect has completed.
- if (retval)
+ if (r->try_connect (&desc, max_wait_time))
return;
}
@@ -86,7 +75,6 @@ TAO_Default_Endpoint_Selector::select_endpoint (TAO::Profile_Transport_Resolver
}
while (r->stub ()->next_profile_retry () != 0);
-
// If we get here, we completely failed to find an endpoint selector
// that we know how to use, so throw an exception.
throw ::CORBA::TRANSIENT (CORBA::OMGVMCID | 2, CORBA::COMPLETED_NO);
diff --git a/TAO/tao/Invocation_Endpoint_Selectors.h b/TAO/tao/Invocation_Endpoint_Selectors.h
index d7142cd86d3..9e29aa34ad7 100644
--- a/TAO/tao/Invocation_Endpoint_Selectors.h
+++ b/TAO/tao/Invocation_Endpoint_Selectors.h
@@ -68,8 +68,7 @@ public:
/// Select the endpoint and set @a r's @c profile_
virtual void select_endpoint (TAO::Profile_Transport_Resolver *r,
- ACE_Time_Value *val
- ) = 0;
+ ACE_Time_Value *val) = 0;
};
@@ -96,8 +95,7 @@ public:
virtual ~TAO_Default_Endpoint_Selector (void);
virtual void select_endpoint (TAO::Profile_Transport_Resolver *r,
- ACE_Time_Value *val
- );
+ ACE_Time_Value *val);
};
diff --git a/TAO/tao/LocateRequest_Invocation.cpp b/TAO/tao/LocateRequest_Invocation.cpp
index eb236487055..b9b34291402 100644
--- a/TAO/tao/LocateRequest_Invocation.cpp
+++ b/TAO/tao/LocateRequest_Invocation.cpp
@@ -61,10 +61,7 @@ namespace TAO
TAO_OutputCDR &cdr = transport->out_stream ();
- int const retval =
- transport->generate_locate_request (tspec, this->details_, cdr);
-
- if (retval == -1)
+ if (transport->generate_locate_request (tspec, this->details_, cdr) == -1)
return TAO_INVOKE_FAILURE;
countdown.update ();
@@ -83,8 +80,7 @@ namespace TAO
if (this->resolver_.transport ()->idle_after_send ())
this->resolver_.transport_released ();
- s =
- this->wait_for_reply (max_wait_time, rd, dispatch_guard);
+ s = this->wait_for_reply (max_wait_time, rd, dispatch_guard);
s = this->check_reply (rd);
@@ -100,8 +96,7 @@ namespace TAO
Invocation_Status
LocateRequest_Invocation::check_reply (TAO_Synch_Reply_Dispatcher &rd)
{
- TAO_InputCDR &cdr =
- rd.reply_cdr ();
+ TAO_InputCDR &cdr = rd.reply_cdr ();
// Set the translators
this->resolver_.transport ()->assign_translators (&cdr, 0);
diff --git a/TAO/tao/LocateRequest_Invocation_Adapter.cpp b/TAO/tao/LocateRequest_Invocation_Adapter.cpp
index 795f38f72f0..ca3413cebd3 100644
--- a/TAO/tao/LocateRequest_Invocation_Adapter.cpp
+++ b/TAO/tao/LocateRequest_Invocation_Adapter.cpp
@@ -48,8 +48,7 @@ namespace TAO
ACE_Time_Value tmp_wait_time;
ACE_Time_Value *max_wait_time = 0;
- bool const is_timeout =
- this->get_timeout (tmp_wait_time);
+ bool const is_timeout = this->get_timeout (tmp_wait_time);
if (is_timeout)
max_wait_time = &tmp_wait_time;
@@ -65,24 +64,18 @@ namespace TAO
try
{
- resolver.init_inconsistent_policies (
- );
+ resolver.init_inconsistent_policies ();
- resolver.resolve (max_wait_time
- );
+ resolver.resolve (max_wait_time);
// Dummy operation details that is used to instantiate the
// LocateRequest class.
- TAO_Operation_Details op (0,
- 0);
+ TAO_Operation_Details op (0, 0);
op.request_id (resolver.transport ()->tms ()->request_id ());
- TAO::LocateRequest_Invocation synch (this->target_,
- resolver,
- op);
+ TAO::LocateRequest_Invocation synch (this->target_, resolver, op);
- s = synch.invoke (max_wait_time
- );
+ s = synch.invoke (max_wait_time);
}
catch (const ::CORBA::INV_POLICY&)
{
diff --git a/TAO/tao/MCAST_Parser.cpp b/TAO/tao/MCAST_Parser.cpp
index 2a8c88be7b7..f9c7f6c60f4 100644
--- a/TAO/tao/MCAST_Parser.cpp
+++ b/TAO/tao/MCAST_Parser.cpp
@@ -37,8 +37,7 @@ TAO_MCAST_Parser::match_prefix (const char *ior_string) const
}
CORBA::Object_ptr
-TAO_MCAST_Parser::parse_string (const char *ior,
- CORBA::ORB_ptr orb)
+TAO_MCAST_Parser::parse_string (const char *ior, CORBA::ORB_ptr orb)
ACE_THROW_SPEC ((CORBA::SystemException))
{
const char *mcast_name =
diff --git a/TAO/tao/ObjectKey_Table.cpp b/TAO/tao/ObjectKey_Table.cpp
index 372cc8069fa..cd7e16d10f1 100644
--- a/TAO/tao/ObjectKey_Table.cpp
+++ b/TAO/tao/ObjectKey_Table.cpp
@@ -163,8 +163,7 @@ TAO::ObjectKey_Table::unbind_i (TAO::Refcounted_ObjectKey *&key_new)
{
TAO::Refcounted_ObjectKey *tmp = 0;
- if (this->table_.unbind (key_new->object_key (),
- tmp) != -1)
+ if (this->table_.unbind (key_new->object_key (), tmp) != -1)
{
// @@ Cant do much if the unbind fails.
// Remove our refcount on the ObjectKey
diff --git a/TAO/tao/Object_Ref_Table.cpp b/TAO/tao/Object_Ref_Table.cpp
index a23bb503ff7..d4c953c27bf 100644
--- a/TAO/tao/Object_Ref_Table.cpp
+++ b/TAO/tao/Object_Ref_Table.cpp
@@ -23,8 +23,7 @@ ACE_RCSID (tao,
TAO_BEGIN_VERSIONED_NAMESPACE_DECL
int
-TAO_Object_Ref_Table::bind (const char *id,
- CORBA::Object_ptr obj)
+TAO_Object_Ref_Table::bind (const char *id, CORBA::Object_ptr obj)
{
// Make sure that the supplied Object reference is valid,
// i.e. not nil.
diff --git a/TAO/tao/Object_Ref_Table.inl b/TAO/tao/Object_Ref_Table.inl
index e9abc371750..09250afe0c3 100644
--- a/TAO/tao/Object_Ref_Table.inl
+++ b/TAO/tao/Object_Ref_Table.inl
@@ -29,8 +29,7 @@ TAO_Object_Ref_Table::register_initial_reference (
}
ACE_INLINE CORBA::Object_ptr
-TAO_Object_Ref_Table::resolve_initial_reference (
- const char * id)
+TAO_Object_Ref_Table::resolve_initial_reference (const char * id)
{
return this->find (id); // Returns a duplicate.
}
diff --git a/TAO/tao/Object_T.cpp b/TAO/tao/Object_T.cpp
index 336a5e34983..1955458c391 100644
--- a/TAO/tao/Object_T.cpp
+++ b/TAO/tao/Object_T.cpp
@@ -22,9 +22,7 @@ namespace TAO
return T::_nil ();
}
- CORBA::Boolean const is_it = obj->_is_a (repo_id);
-
- if (is_it == false)
+ if (obj->_is_a (repo_id) == false)
{
return T::_nil ();
}
diff --git a/TAO/tao/RTScheduling/Request_Interceptor.cpp b/TAO/tao/RTScheduling/Request_Interceptor.cpp
index c499d30905f..1cca5d0c1e9 100644
--- a/TAO/tao/RTScheduling/Request_Interceptor.cpp
+++ b/TAO/tao/RTScheduling/Request_Interceptor.cpp
@@ -43,7 +43,6 @@ Client_Interceptor::send_request (PortableInterceptor::ClientRequestInfo_ptr ri)
// If this is a one way request
if (!ri->response_expected ())
{
-
// Generate GUID.
RTScheduling::Current::IdType guid;
guid.length (sizeof(long));
@@ -166,12 +165,10 @@ Client_Interceptor::receive_exception (PortableInterceptor::ClientRequestInfo_pt
ACE_DEBUG ((LM_DEBUG,
"Client_Interceptor::receive_exception\n"));
-
- TAO_RTScheduler_Current_i *current = 0;
-
TAO_TSS_Resources *tss = TAO_TSS_Resources::instance ();
- current = static_cast<TAO_RTScheduler_Current_i *> (tss->rtscheduler_current_impl_);
+ TAO_RTScheduler_Current_i *current =
+ static_cast<TAO_RTScheduler_Current_i *> (tss->rtscheduler_current_impl_);
if (current != 0)
{
@@ -182,8 +179,7 @@ Client_Interceptor::receive_exception (PortableInterceptor::ClientRequestInfo_pt
return;
}
- CORBA::Any_var ex =
- ri->received_exception ();
+ CORBA::Any_var ex = ri->received_exception ();
CORBA::TypeCode_var type = ex->type ();
if (CORBA::is_nil (type.in ()))
@@ -199,7 +195,6 @@ Client_Interceptor::receive_exception (PortableInterceptor::ClientRequestInfo_pt
"Received Exception %s\n",
ACE_TEXT_CHAR_TO_TCHAR (id)));
-
// If the remote host threw a THREAD_CANCELLED
// exception, make sure to take the appropriate
// local action.
diff --git a/TAO/tao/Strategies/SCIOP_Endpoint.cpp b/TAO/tao/Strategies/SCIOP_Endpoint.cpp
index 9b7d02c3e4a..a4c4cc1b67d 100644
--- a/TAO/tao/Strategies/SCIOP_Endpoint.cpp
+++ b/TAO/tao/Strategies/SCIOP_Endpoint.cpp
@@ -25,7 +25,7 @@ ACE_RCSID (Strategies,
TAO_BEGIN_VERSIONED_NAMESPACE_DECL
TAO_SCIOP_Endpoint::TAO_SCIOP_Endpoint (const ACE_INET_Addr &addr,
- int use_dotted_decimal_addresses)
+ int use_dotted_decimal_addresses)
: TAO_Endpoint (TAO_TAG_SCIOP_PROFILE)
, host_ ()
, port_ (683) // default port (IANA assigned)
@@ -249,8 +249,7 @@ TAO_SCIOP_Endpoint::object_addr (void) const
void
TAO_SCIOP_Endpoint::object_addr_i (void) const
{
- if (this->object_addr_.set (this->port_,
- this->host_.in ()) == -1)
+ if (this->object_addr_.set (this->port_, this->host_.in ()) == -1)
{
// If this call fails, it most likely due a hostname
// lookup failure caused by a DNS misconfiguration. If
diff --git a/TAO/tao/Strategies/SCIOP_Factory.cpp b/TAO/tao/Strategies/SCIOP_Factory.cpp
index 8734e78cdbc..ca3dfb1c365 100644
--- a/TAO/tao/Strategies/SCIOP_Factory.cpp
+++ b/TAO/tao/Strategies/SCIOP_Factory.cpp
@@ -56,8 +56,7 @@ TAO_SCIOP_Protocol_Factory::make_acceptor (void)
}
int
-TAO_SCIOP_Protocol_Factory::init (int /* argc */,
- ACE_TCHAR* /* argv */ [])
+TAO_SCIOP_Protocol_Factory::init (int /* argc */, ACE_TCHAR* /* argv */ [])
{
return 0;
}
diff --git a/TAO/tao/Strategies/SCIOP_Transport.cpp b/TAO/tao/Strategies/SCIOP_Transport.cpp
index f306345bca0..65b0fe7b905 100644
--- a/TAO/tao/Strategies/SCIOP_Transport.cpp
+++ b/TAO/tao/Strategies/SCIOP_Transport.cpp
@@ -332,8 +332,7 @@ TAO_SCIOP_Transport::get_listen_point (
// Get the local address of the connection
ACE_INET_Addr local_addr;
- if (this->connection_handler_->peer ().get_local_addr (local_addr)
- == -1)
+ if (this->connection_handler_->peer ().get_local_addr (local_addr) == -1)
{
ACE_ERROR_RETURN ((LM_ERROR,
ACE_TEXT ("(%P|%t) Could not resolve local ")
@@ -358,15 +357,12 @@ TAO_SCIOP_Transport::get_listen_point (
-1);
}
- for (size_t index = 0;
- index != count;
- index++)
+ for (size_t index = 0; index != count; index++)
{
- if (local_addr.get_ip_address()
- == endpoint_addr[index].get_ip_address())
+ if (local_addr.get_ip_address() == endpoint_addr[index].get_ip_address())
{
// Get the count of the number of elements
- CORBA::ULong len = listen_point_list.length ();
+ CORBA::ULong const len = listen_point_list.length ();
// Increase the length by 1
listen_point_list.length (len + 1);
diff --git a/TAO/tao/Strategies/SHMIOP_Acceptor.cpp b/TAO/tao/Strategies/SHMIOP_Acceptor.cpp
index d90a04cc655..bc8a26a7ea9 100644
--- a/TAO/tao/Strategies/SHMIOP_Acceptor.cpp
+++ b/TAO/tao/Strategies/SHMIOP_Acceptor.cpp
@@ -59,13 +59,9 @@ TAO_SHMIOP_Acceptor::create_profile (const TAO::ObjectKey &object_key,
// Check if multiple endpoints should be put in one profile or
// if they should be spread across multiple profiles.
if (priority == TAO_INVALID_PRIORITY)
- return this->create_new_profile (object_key,
- mprofile,
- priority);
+ return this->create_new_profile (object_key, mprofile, priority);
else
- return this->create_shared_profile (object_key,
- mprofile,
- priority);
+ return this->create_shared_profile (object_key, mprofile, priority);
}
int
@@ -135,9 +131,7 @@ TAO_SHMIOP_Acceptor::create_shared_profile (const TAO::ObjectKey &object_key,
{
// If <mprofile> doesn't contain SHMIOP_Profile, we need to create
// one.
- return create_new_profile (object_key,
- mprofile,
- priority);
+ return create_new_profile (object_key, mprofile, priority);
}
else
{
@@ -232,8 +226,7 @@ TAO_SHMIOP_Acceptor::open_default (TAO_ORB_Core *orb_core,
// address.
this->host_ = this->address_.get_host_name ();
- return this->open_i (orb_core,
- reactor);
+ return this->open_i (orb_core, reactor);
}
int
@@ -366,8 +359,7 @@ TAO_SHMIOP_Acceptor::object_key (IOP::TaggedProfile &profile,
// Read the version. We just read it here. We don't*do any*
// processing.
- if (!(cdr.read_octet (major)
- && cdr.read_octet (minor)))
+ if (!(cdr.read_octet (major) && cdr.read_octet (minor)))
{
if (TAO_debug_level > 0)
{
diff --git a/TAO/tao/Strategies/SHMIOP_Transport.cpp b/TAO/tao/Strategies/SHMIOP_Transport.cpp
index bb99b50d002..6f66f057062 100644
--- a/TAO/tao/Strategies/SHMIOP_Transport.cpp
+++ b/TAO/tao/Strategies/SHMIOP_Transport.cpp
@@ -138,8 +138,8 @@ TAO_SHMIOP_Transport::recv (char *buf,
}
int
-TAO_SHMIOP_Transport::handle_input (TAO_Resume_Handle &rh,
- ACE_Time_Value *max_wait_time,
+TAO_SHMIOP_Transport::handle_input (TAO_Resume_Handle &rh,
+ ACE_Time_Value *max_wait_time,
int)
{
if (TAO_debug_level > 3)
@@ -180,7 +180,7 @@ TAO_SHMIOP_Transport::handle_input (TAO_Resume_Handle &rh,
const size_t missing_header_data = this->messaging_object ()->header_length ();
- if (missing_header_data == 0)
+ if (missing_header_data == 0)
{
return -1;
}
@@ -226,7 +226,7 @@ TAO_SHMIOP_Transport::handle_input (TAO_Resume_Handle &rh,
mesg_length) == -1)
return -1;
- if (qd.missing_data_ == TAO_MISSING_DATA_UNDEFINED)
+ if (qd.missing_data_ == TAO_MISSING_DATA_UNDEFINED)
{
// parse/marshal error happened
return -1;
@@ -237,7 +237,7 @@ TAO_SHMIOP_Transport::handle_input (TAO_Resume_Handle &rh,
// we read too much data
return -1;
}
-
+
if (message_block.space () < qd.missing_data_)
{
const size_t message_size = message_block.length ()
@@ -295,7 +295,7 @@ TAO_SHMIOP_Transport::handle_input (TAO_Resume_Handle &rh,
{
return -1;
}
-
+
return 0;
}
@@ -362,8 +362,7 @@ int
TAO_SHMIOP_Transport::messaging_init (CORBA::Octet major,
CORBA::Octet minor)
{
- this->messaging_object_->init (major,
- minor);
+ this->messaging_object_->init (major, minor);
return 1;
}
diff --git a/TAO/tao/Strategies/SHMIOP_Transport.h b/TAO/tao/Strategies/SHMIOP_Transport.h
index e44b79d4173..7224a002623 100644
--- a/TAO/tao/Strategies/SHMIOP_Transport.h
+++ b/TAO/tao/Strategies/SHMIOP_Transport.h
@@ -104,8 +104,7 @@ public:
ACE_Time_Value *max_time_wait = 0);
/// Initialising the messaging object
- virtual int messaging_init (CORBA::Octet major,
- CORBA::Octet minor);
+ virtual int messaging_init (CORBA::Octet major, CORBA::Octet minor);
private:
/// The connection service handler used for accessing lower layer
diff --git a/TAO/tao/Strategies/UIOP_Transport.cpp b/TAO/tao/Strategies/UIOP_Transport.cpp
index c3cde036f2e..cce1c02c833 100644
--- a/TAO/tao/Strategies/UIOP_Transport.cpp
+++ b/TAO/tao/Strategies/UIOP_Transport.cpp
@@ -80,10 +80,8 @@ TAO_UIOP_Transport::send (iovec *iov, int iovcnt,
size_t &bytes_transferred,
const ACE_Time_Value *max_wait_time)
{
- const ssize_t retval =
- this->connection_handler_->peer ().sendv (iov,
- iovcnt,
- max_wait_time);
+ ssize_t const retval =
+ this->connection_handler_->peer ().sendv (iov, iovcnt, max_wait_time);
if (retval > 0)
bytes_transferred = retval;
@@ -136,15 +134,10 @@ TAO_UIOP_Transport::send_request (TAO_Stub *stub,
int message_semantics,
ACE_Time_Value *max_wait_time)
{
- if (this->ws_->sending_request (orb_core,
- message_semantics) == -1)
+ if (this->ws_->sending_request (orb_core, message_semantics) == -1)
return -1;
- if (this->send_message (stream,
- stub,
- message_semantics,
- max_wait_time) == -1)
-
+ if (this->send_message (stream, stub, message_semantics, max_wait_time) == -1)
return -1;
this->first_request_sent();
@@ -190,8 +183,7 @@ int
TAO_UIOP_Transport::messaging_init (CORBA::Octet major,
CORBA::Octet minor)
{
- this->messaging_object_->init (major,
- minor);
+ this->messaging_object_->init (major, minor);
return 1;
}
diff --git a/TAO/tao/TransportCurrent/Current_ORBInitializer.h b/TAO/tao/TransportCurrent/Current_ORBInitializer.h
index 7b1ff98c6a2..516c6205c02 100644
--- a/TAO/tao/TransportCurrent/Current_ORBInitializer.h
+++ b/TAO/tao/TransportCurrent/Current_ORBInitializer.h
@@ -36,17 +36,12 @@ namespace TAO
public:
Current_ORBInitializer (const ACE_TCHAR* id);
-
protected:
virtual TAO::Transport::Current_ptr
- make_current_instance (TAO_ORB_Core* c,
- size_t s
- )
+ make_current_instance (TAO_ORB_Core* c, size_t s)
ACE_THROW_SPEC ((CORBA::SystemException));
};
-
}
-
}
TAO_END_VERSIONED_NAMESPACE_DECL
diff --git a/TAO/tao/TransportCurrent/Current_ORBInitializer_Base.h b/TAO/tao/TransportCurrent/Current_ORBInitializer_Base.h
index cb4ce2fa446..d2e10d98e36 100644
--- a/TAO/tao/TransportCurrent/Current_ORBInitializer_Base.h
+++ b/TAO/tao/TransportCurrent/Current_ORBInitializer_Base.h
@@ -49,8 +49,7 @@ namespace TAO
ACE_THROW_SPEC ((CORBA::SystemException));
protected:
virtual TAO::Transport::Current_ptr
- make_current_instance (TAO_ORB_Core* core,
- size_t tss_slot_id)
+ make_current_instance (TAO_ORB_Core* core, size_t tss_slot_id)
ACE_THROW_SPEC ((CORBA::SystemException)) = 0;
protected:
const ACE_TString id_;
diff --git a/TAO/tao/Valuetype/AbstractBase.cpp b/TAO/tao/Valuetype/AbstractBase.cpp
index 9d64485d221..d0359c951a5 100644
--- a/TAO/tao/Valuetype/AbstractBase.cpp
+++ b/TAO/tao/Valuetype/AbstractBase.cpp
@@ -179,10 +179,7 @@ CORBA::AbstractBase::_is_a (const char *type_id)
return this->equivalent_obj_->_is_a (type_id);
}
- int const cmp = ACE_OS::strcmp (type_id,
- "IDL:omg.org/CORBA/AbstractBase:1.0");
-
- return (cmp == 0);
+ return (ACE_OS::strcmp (type_id, "IDL:omg.org/CORBA/AbstractBase:1.0") == 0);
}
const char *
diff --git a/TAO/tao/Valuetype/ValueBase.cpp b/TAO/tao/Valuetype/ValueBase.cpp
index c6f9b5e9668..e701faa9749 100644
--- a/TAO/tao/Valuetype/ValueBase.cpp
+++ b/TAO/tao/Valuetype/ValueBase.cpp
@@ -170,9 +170,7 @@ CORBA::ValueBase::_tao_unmarshal (TAO_InputCDR &strm,
// new_object->_tao_unmarshal_post ()
CORBA::Boolean const retval =
- CORBA::ValueBase::_tao_unmarshal_pre (strm,
- new_object,
- 0);
+ CORBA::ValueBase::_tao_unmarshal_pre (strm, new_object, 0);
if (!retval)
{
@@ -687,7 +685,7 @@ TAO_ChunkInfo::handle_chunking (TAO_InputCDR &strm)
//that has parents.
if (the_rd_ptr < this->chunk_octets_end_pos_)
{
- this->value_nesting_level_ ++;
+ ++this->value_nesting_level_;
return true;
}
@@ -721,8 +719,7 @@ TAO_ChunkInfo::handle_chunking (TAO_InputCDR &strm)
}
this->value_nesting_level_ = - tag;
- this->value_nesting_level_--;
-
+ --this->value_nesting_level_;
this->chunk_octets_end_pos_ = 0;
@@ -737,7 +734,7 @@ TAO_ChunkInfo::handle_chunking (TAO_InputCDR &strm)
{
// Read the chunk size of another chunk.
this->chunk_octets_end_pos_ = strm.rd_ptr () + tag;
- this->value_nesting_level_ ++;
+ ++this->value_nesting_level_;
}
else // (tag >= 0x7fffff00)
{
@@ -1004,8 +1001,7 @@ CORBA::Boolean
operator>> (TAO_InputCDR &strm,
CORBA::ValueBase *&_tao_valuetype)
{
- return CORBA::ValueBase::_tao_unmarshal (strm,
- _tao_valuetype);
+ return CORBA::ValueBase::_tao_unmarshal (strm, _tao_valuetype);
}
// =============== Template Specializations =====================
diff --git a/TAO/tao/Valuetype/ValueFactory.cpp b/TAO/tao/Valuetype/ValueFactory.cpp
index 473780b8790..a03b7be5bc7 100644
--- a/TAO/tao/Valuetype/ValueFactory.cpp
+++ b/TAO/tao/Valuetype/ValueFactory.cpp
@@ -47,7 +47,7 @@ CORBA::ValueFactoryBase::_add_ref (void)
void
CORBA::ValueFactoryBase::_remove_ref (void)
{
- const CORBA::ULong new_count = --this->_tao_reference_count_;
+ CORBA::ULong const new_count = --this->_tao_reference_count_;
if (new_count == 0)
delete this;
diff --git a/TAO/tao/Valuetype/ValueFactory_Map.cpp b/TAO/tao/Valuetype/ValueFactory_Map.cpp
index f33af298e5e..9100f319cf8 100644
--- a/TAO/tao/Valuetype/ValueFactory_Map.cpp
+++ b/TAO/tao/Valuetype/ValueFactory_Map.cpp
@@ -69,8 +69,8 @@ TAO_ValueFactory_Map::unbind (const char *repo_id,
ACE_GUARD_RETURN(TAO_SYNCH_MUTEX, guard, this->mutex_, -1);
FACTORY_MAP_MANAGER::ENTRY *prev_entry = 0;
- int ret = this->map_.find (repo_id,
- prev_entry);
+ int ret = this->map_.find (repo_id, prev_entry);
+
if (ret == 0) // there was a matching factory
{
// set factory to the previous factory,
@@ -94,8 +94,7 @@ TAO_ValueFactory_Map::find (const char *repo_id,
{
ACE_GUARD_RETURN(TAO_SYNCH_MUTEX, guard, this->mutex_, -1);
- int const ret = this->map_.find (repo_id,
- factory);
+ int const ret = this->map_.find (repo_id, factory);
if (ret > -1)
{
factory->_add_ref (); // The caller gets one reference as gift.
diff --git a/TAO/tao/operation_details.cpp b/TAO/tao/operation_details.cpp
index 4252f968285..880879e54ab 100644
--- a/TAO/tao/operation_details.cpp
+++ b/TAO/tao/operation_details.cpp
@@ -48,6 +48,19 @@ TAO_Operation_Details::corba_exception (const char *id)
}
bool
+TAO_Operation_Details::has_exception (::CORBA::Exception& ex) const
+{
+ for (CORBA::ULong i = 0; i != this->ex_count_; ++i)
+ {
+ if (ACE_OS::strcmp (ex._rep_id (), this->ex_data_[i].id) == 0)
+ {
+ return true;
+ }
+ }
+ return false;
+}
+
+bool
TAO_Operation_Details::marshal_args (TAO_OutputCDR &cdr)
{
for (CORBA::ULong i = 0; i != this->num_args_; ++i)
diff --git a/TAO/tao/operation_details.h b/TAO/tao/operation_details.h
index 38cbc0314be..1baf4c9b93e 100644
--- a/TAO/tao/operation_details.h
+++ b/TAO/tao/operation_details.h
@@ -24,7 +24,6 @@
#include "tao/TimeBaseC.h"
#include "tao/target_specification.h"
-
TAO_BEGIN_VERSIONED_NAMESPACE_DECL
/// Forward declarations
@@ -106,8 +105,7 @@ public:
TAO_Service_Context &reply_service_context (void);
const TAO_Service_Context &reply_service_context (void) const;
- /// Reset the contents of the service context lists that we
- /// hold.
+ /// Reset the contents of the service context lists that we hold.
void reset_request_service_info (void);
void reset_reply_service_info (void);
@@ -135,6 +133,9 @@ public:
CORBA::Exception *corba_exception (const char *ex)
ACE_THROW_SPEC ((CORBA::SystemException));
+ /// Check whether exception @a ex is in the signature of this operation
+ bool has_exception (::CORBA::Exception& ex) const;
+
/**
* @name Helper methods used by the Invocation classes.
*/
@@ -222,7 +223,7 @@ private:
#endif /*TAO_HAS_INTERCEPTORS == 1*/
/// The dii request flag.
- CORBA::Boolean is_dii_request_;
+ CORBA::Boolean is_dii_request_;
};
TAO_END_VERSIONED_NAMESPACE_DECL
diff --git a/TAO/tao/operation_details.inl b/TAO/tao/operation_details.inl
index 61063aa9a60..3ebb8296e02 100644
--- a/TAO/tao/operation_details.inl
+++ b/TAO/tao/operation_details.inl
@@ -210,7 +210,6 @@ TAO_Operation_Details::ft_retention_id (void) const
}
#endif /*TAO_HAS_INTERCEPTORS == 1*/
-
ACE_INLINE CORBA::Boolean
TAO_Operation_Details::is_dii_request (void) const
{