summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorsma <sma@ae88bc3d-4319-0410-8dbf-d08b4c9d3795>2013-05-21 11:07:05 +0000
committersma <sma@ae88bc3d-4319-0410-8dbf-d08b4c9d3795>2013-05-21 11:07:05 +0000
commit7fb7910e592e12cd62cc4e0ff6187036f8294805 (patch)
treea4411d989189fb886e8085656583763a67da6084
parent2d22dd2dbd81bd87444c355be4fffd94d885e9d8 (diff)
downloadATCD-7fb7910e592e12cd62cc4e0ff6187036f8294805.tar.gz
Tue May 21 11:07:00 UTC 2013 Simon Massey <simon dot massey at prismtech dot com> Add sanity check for SndSock value obtained from system
-rw-r--r--TAO/ChangeLog6
-rw-r--r--TAO/orbsvcs/orbsvcs/PortableGroup/UIPMC_Connection_Handler.cpp16
2 files changed, 21 insertions, 1 deletions
diff --git a/TAO/ChangeLog b/TAO/ChangeLog
index a27c8f17fbc..12aadd6f9f3 100644
--- a/TAO/ChangeLog
+++ b/TAO/ChangeLog
@@ -1,3 +1,9 @@
+Tue May 21 11:07:00 UTC 2013 Simon Massey <simon dot massey at prismtech dot com>
+
+ * orbsvcs/orbsvcs/PortableGroup/UIPMC_Connection_Handler.cpp:
+
+ Add sanity check for SndSock value obtained from system.
+
Mon May 20 16:41:51 UTC 2013 Phil Mesnier <mesnier_p@ociweb.com>
* orbsvcs/ImplRepo_Service/AsyncListManager.cpp:
diff --git a/TAO/orbsvcs/orbsvcs/PortableGroup/UIPMC_Connection_Handler.cpp b/TAO/orbsvcs/orbsvcs/PortableGroup/UIPMC_Connection_Handler.cpp
index 1251d3e2aa3..d97a8b2a3cc 100644
--- a/TAO/orbsvcs/orbsvcs/PortableGroup/UIPMC_Connection_Handler.cpp
+++ b/TAO/orbsvcs/orbsvcs/PortableGroup/UIPMC_Connection_Handler.cpp
@@ -274,7 +274,21 @@ TAO_UIPMC_Connection_Handler::open (void*)
// internal data structures seporating each packet) and this doubled
// value is what is returned by the get_option, so it is best to halve.
this->send_hi_water_mark_ >>= 1;
- if (TAO_debug_level)
+
+ // Also Note that some kernals return stupid values (such as solaris
+ // when using the loopback interface) so cater for rediculously small
+ // values.
+ if (this->send_hi_water_mark_ < 256u)
+ {
+ this->send_hi_water_mark_ = 256u;
+ if (TAO_debug_level)
+ ACE_ERROR ((LM_ERROR,
+ ACE_TEXT ("TAO (%P|%t) - UIPMC_Connection_Handler::")
+ ACE_TEXT ("open, -ORBSendHighWaterMark not specified, ")
+ ACE_TEXT ("using value of %u bytes\n"),
+ this->send_hi_water_mark_));
+ }
+ else if (TAO_debug_level)
ORBSVCS_ERROR ((LM_ERROR,
ACE_TEXT ("TAO (%P|%t) - UIPMC_Connection_Handler::")
ACE_TEXT ("open, -ORBSendHighWaterMark not specified, ")