summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--TAO/tao/GIOP_Message_Base.cpp36
-rw-r--r--TAO/tao/GIOP_Message_Handler.cpp7
-rw-r--r--TAO/tao/GIOP_Message_State.cpp1
-rw-r--r--TAO/tao/IIOP_Transport.cpp9
4 files changed, 7 insertions, 46 deletions
diff --git a/TAO/tao/GIOP_Message_Base.cpp b/TAO/tao/GIOP_Message_Base.cpp
index 117f6a95afb..22194389b03 100644
--- a/TAO/tao/GIOP_Message_Base.cpp
+++ b/TAO/tao/GIOP_Message_Base.cpp
@@ -199,27 +199,8 @@ TAO_GIOP_Message_Base::read_message (TAO_Transport *transport,
this->set_state (state.giop_version.major,
state.giop_version.minor);
- /*if (TAO_debug_level >= 4)
- {
- size_t len = TAO_GIOP_MESSAGE_HEADER_LEN ;
-
- // At this point we could have parsed the
- char *buf = this->message_handler_.rd_ptr ();
- buf -= len;
- size_t msg_len =
- state.message_size + len;
- this->dump_msg ("recv",
- ACE_reinterpret_cast (u_char *,
- buf),
- msg_len);
- }*/
-
int retval = this->message_handler_.is_message_ready ();
- if (retval == 1)
- {
-
- }
return retval;
}
@@ -1188,23 +1169,6 @@ TAO_GIOP_Message_Base::more_messages (void)
if (retval == 1)
{
- /*if (TAO_debug_level >= 4)
- {
- size_t len = TAO_GIOP_MESSAGE_HEADER_LEN ;
-
- char *buf = this->message_handler_.rd_ptr ();
- buf -= len;
- size_t msg_len =
- state.message_size + len;
-
- this->dump_msg ("recv",
- ACE_reinterpret_cast (u_char *,
- buf),
- msg_len);
- }*/
-
- // We have a message ready. This can be processed by the higher
- // layers
return TAO_MESSAGE_BLOCK_NEEDS_PROCESSING;
}
diff --git a/TAO/tao/GIOP_Message_Handler.cpp b/TAO/tao/GIOP_Message_Handler.cpp
index f636fbb630b..acac6f456bb 100644
--- a/TAO/tao/GIOP_Message_Handler.cpp
+++ b/TAO/tao/GIOP_Message_Handler.cpp
@@ -285,7 +285,6 @@ TAO_GIOP_Message_Handler::is_message_ready (void)
// only the first part of the fragment.
this->message_status_ = TAO_GIOP_WAITING_FOR_HEADER;
-
if (TAO_debug_level >= 4)
this->mesg_base_->dump_msg (
"Recv msg",
@@ -307,7 +306,6 @@ TAO_GIOP_Message_Handler::is_message_ready (void)
this->supp_buffer_.copy (this->current_buffer_.rd_ptr (),
this->message_state_.message_size);
-
if (TAO_debug_level >= 4)
this->mesg_base_->dump_msg (
"Recv msg",
@@ -319,7 +317,6 @@ TAO_GIOP_Message_Handler::is_message_ready (void)
// rd_ptr in <current_buffer_> after that message
this->current_buffer_.rd_ptr (this->message_state_.message_size);
-
return this->message_state_.is_complete (this->supp_buffer_);
}
}
@@ -346,11 +343,13 @@ TAO_GIOP_Message_Handler::more_messages (void)
// wr_ptr.
this->align_left_info ();
this->message_status_ = TAO_GIOP_WAITING_FOR_HEADER;
+
+ // No more meaningful messages
return TAO_MESSAGE_BLOCK_INCOMPLETE;
}
}
- // No more meaningful messages
+
return TAO_MESSAGE_BLOCK_COMPLETE;
}
diff --git a/TAO/tao/GIOP_Message_State.cpp b/TAO/tao/GIOP_Message_State.cpp
index b935b577a90..24afe75123c 100644
--- a/TAO/tao/GIOP_Message_State.cpp
+++ b/TAO/tao/GIOP_Message_State.cpp
@@ -18,7 +18,6 @@ TAO_GIOP_Message_State::TAO_GIOP_Message_State (TAO_ORB_Core* orb_core)
message_type (TAO_GIOP_MESSAGERROR),
message_size (0),
request_id (0),
-
// Problem similar to GIOP_Message_handler.cpp - Bala
fragmented_messages (ACE_CDR::DEFAULT_BUFSIZE)
{
diff --git a/TAO/tao/IIOP_Transport.cpp b/TAO/tao/IIOP_Transport.cpp
index d52971418ae..11ab646bac4 100644
--- a/TAO/tao/IIOP_Transport.cpp
+++ b/TAO/tao/IIOP_Transport.cpp
@@ -169,12 +169,13 @@ TAO_IIOP_Transport::read_process_message (ACE_Time_Value *max_wait_time,
return result;
// Now we know that we have been able to read the complete message
- // here..
- result = 2; // Dummy
- while (result > 1)
+ // here.. We loop here to see whether we have read more than one
+ // message in our read.
+ do
{
result = this->process_message ();
}
+ while (result > 1);
return result;
}
@@ -475,8 +476,6 @@ TAO_IIOP_Transport::process_message (void)
return -1;
}
- // this->messaging_object_->reset ();
-
return this->messaging_object_->more_messages ();
}