summaryrefslogtreecommitdiff
path: root/TAO/tao/GIOP_Message_Connectors.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'TAO/tao/GIOP_Message_Connectors.cpp')
-rw-r--r--TAO/tao/GIOP_Message_Connectors.cpp49
1 files changed, 38 insertions, 11 deletions
diff --git a/TAO/tao/GIOP_Message_Connectors.cpp b/TAO/tao/GIOP_Message_Connectors.cpp
index e667146fac2..b32f4124252 100644
--- a/TAO/tao/GIOP_Message_Connectors.cpp
+++ b/TAO/tao/GIOP_Message_Connectors.cpp
@@ -59,8 +59,7 @@ TAO_GIOP_Message_Connectors::
int
TAO_GIOP_Message_Connectors::
parse_reply (TAO_Message_State_Factory &mesg_state,
- TAO_Pluggable_Connector_Params &params,
- CORBA::ULong &reply_status)
+ TAO_Pluggable_Connector_Params &params)
{
// Cast to the GIOP Message state
@@ -68,7 +67,7 @@ TAO_GIOP_Message_Connectors::
&mesg_state);
// Read the request id
- if (!state->cdr.read_ulong (params.request_id))
+ if (!state->cdr.read_ulong (params.request_id_))
{
if (TAO_debug_level > 0)
ACE_DEBUG ((LM_DEBUG,
@@ -79,8 +78,10 @@ TAO_GIOP_Message_Connectors::
// and the reply status type. status can be NO_EXCEPTION,
// SYSTEM_EXCEPTION, USER_EXCEPTION, LOCATION_FORWARD
- // CAnnot handle LOCATION_FORWARD_PERM here
- if (!state->cdr.read_ulong (reply_status))
+
+ // Cannot handle LOCATION_FORWARD_PERM here
+ CORBA::ULong rep_stat = 0;
+ if (!state->cdr.read_ulong (rep_stat))
{
if (TAO_debug_level > 0)
ACE_DEBUG ((LM_DEBUG,
@@ -88,7 +89,33 @@ TAO_GIOP_Message_Connectors::
"extracting reply status\n"));
return -1;
}
-
+
+ // Pass the right Pluggable interface code to the transport layer
+ switch (rep_stat)
+ {
+ // Request completed successfully
+ case TAO_GIOP_NO_EXCEPTION:
+ params.reply_status_ = TAO_PLUGGABLE_MESSAGE_NO_EXCEPTION;
+ break;
+
+ // Request terminated with user exception
+ case TAO_GIOP_USER_EXCEPTION:
+ params.reply_status_ = TAO_PLUGGABLE_MESSAGE_USER_EXCEPTION;
+ break;
+ // Request terminated with system exception
+ case TAO_GIOP_SYSTEM_EXCEPTION:
+ params.reply_status_ = TAO_PLUGGABLE_MESSAGE_SYSTEM_EXCEPTION;
+ break;
+ // Reply is a location forward type
+ case TAO_GIOP_LOCATION_FORWARD:
+ params.reply_status_ = TAO_PLUGGABLE_MESSAGE_LOCATION_FORWARD;
+ break;
+ default:
+ if (TAO_debug_level > 0)
+ ACE_DEBUG ((LM_DEBUG,
+ ASYS_TEXT ("(%N|%l) Unknown reply status \n")));
+ }
+
return 0;
}
@@ -209,8 +236,8 @@ TAO_GIOP_Message_Connector_11::
int
TAO_GIOP_Message_Connector_11::
parse_reply (TAO_Message_State_Factory &mesg_state,
- TAO_Pluggable_Connector_Params &params,
- CORBA::ULong &reply_status)
+ TAO_Pluggable_Connector_Params &params)
+
{
// Cast to the GIOP Message state
TAO_GIOP_Message_State *state = ACE_dynamic_cast (TAO_GIOP_Message_State *,
@@ -239,7 +266,7 @@ TAO_GIOP_Message_Connector_11::
// Handle after the switch
break;
case TAO_GIOP_REPLY:
- if ((state->cdr >> params.svc_ctx) == 0)
+ if ((state->cdr >> params.svc_ctx_) == 0)
{
if (TAO_debug_level > 0)
ACE_DEBUG ((LM_DEBUG,
@@ -255,8 +282,8 @@ TAO_GIOP_Message_Connector_11::
}
if (TAO_GIOP_Message_Connectors::parse_reply (*state,
- params,
- reply_status) == -1)
+ params)
+ == -1)
return -1;
return 0;