summaryrefslogtreecommitdiff
path: root/TAO
diff options
context:
space:
mode:
authorolli <olli@ae88bc3d-4319-0410-8dbf-d08b4c9d3795>2011-03-17 09:46:30 +0000
committerolli <olli@ae88bc3d-4319-0410-8dbf-d08b4c9d3795>2011-03-17 09:46:30 +0000
commit1e3eeeba2675a9cdc33def87358840d1e9723515 (patch)
treed2513d69ee602224acc76b380f7ba0fb3ddbd677 /TAO
parent575ec9dcd0f77f3ddce2841b322a529cd25b636a (diff)
downloadATCD-1e3eeeba2675a9cdc33def87358840d1e9723515.tar.gz
ChangeLogTag: Thu Mar 17 09:45:43 UTC 2011 Olli Savia <ops@iki.fi>
Diffstat (limited to 'TAO')
-rw-r--r--TAO/ChangeLog6
-rw-r--r--TAO/orbsvcs/tests/EC_Mcast/EC_Mcast.cpp10
-rw-r--r--TAO/orbsvcs/tests/EC_Mcast/EC_Mcast.h6
3 files changed, 14 insertions, 8 deletions
diff --git a/TAO/ChangeLog b/TAO/ChangeLog
index 9af5cde9a4a..248d1c552e4 100644
--- a/TAO/ChangeLog
+++ b/TAO/ChangeLog
@@ -1,3 +1,9 @@
+Thu Mar 17 09:45:43 UTC 2011 Olli Savia <ops@iki.fi>
+
+ * orbsvcs/tests/EC_Mcast/EC_Mcast.h:
+ * orbsvcs/tests/EC_Mcast/EC_Mcast.cpp:
+ Fixes due to ACE rand_r() changes.
+
Thu Mar 17 09:43:12 UTC 2011 Olli Savia <ops@iki.fi>
* orbsvcs/tests/Event/Basic/Observer.h:
diff --git a/TAO/orbsvcs/tests/EC_Mcast/EC_Mcast.cpp b/TAO/orbsvcs/tests/EC_Mcast/EC_Mcast.cpp
index 6b029368d05..10b0777b219 100644
--- a/TAO/orbsvcs/tests/EC_Mcast/EC_Mcast.cpp
+++ b/TAO/orbsvcs/tests/EC_Mcast/EC_Mcast.cpp
@@ -736,7 +736,7 @@ ECM_Consumer::ECM_Consumer (ECM_Local_Federation *federation)
void
ECM_Consumer::open (const char*,
RtecEventChannelAdmin::EventChannel_ptr ec,
- ACE_RANDR_TYPE &seed)
+ unsigned int *seed)
{
// The worst case execution time is far less than 2
// milliseconds, but that is a safe estimate....
@@ -751,7 +751,7 @@ ECM_Consumer::open (const char*,
}
void
-ECM_Consumer::connect (ACE_RANDR_TYPE &seed)
+ECM_Consumer::connect (unsigned int *seed)
{
if (CORBA::is_nil (this->consumer_admin_.in ()))
return;
@@ -880,7 +880,7 @@ ECM_Local_Federation::open (int event_count,
ACE_OS::strcpy (buf, this->federation_->name ());
ACE_OS::strcat (buf, "/consumer");
- this->consumer_.open (buf, ec, this->seed_);
+ this->consumer_.open (buf, ec, &this->seed_);
this->last_subscription_change_ = ACE_OS::gettimeofday ();
}
@@ -933,7 +933,7 @@ ECM_Local_Federation::supplier_timeout (RtecEventComm::PushConsumer_ptr consumer
ACE_Time_Value delta = ACE_OS::gettimeofday () -
this->last_subscription_change_;
- unsigned int x = ACE_OS::rand_r (this->seed_);
+ unsigned int x = ACE_OS::rand_r (&this->seed_);
double p = double (x) / RAND_MAX;
double maxp = double (delta.msec ()) / this->subscription_change_period_;
@@ -943,7 +943,7 @@ ECM_Local_Federation::supplier_timeout (RtecEventComm::PushConsumer_ptr consumer
"Reconfiguring federation %s: %f %f [%d]\n",
this->name (), p, maxp, x));
this->consumer_.disconnect ();
- this->consumer_.connect (this->seed_);
+ this->consumer_.connect (&this->seed_);
this->last_subscription_change_ = ACE_OS::gettimeofday ();
}
}
diff --git a/TAO/orbsvcs/tests/EC_Mcast/EC_Mcast.h b/TAO/orbsvcs/tests/EC_Mcast/EC_Mcast.h
index 8a7d89da3a4..52437fb8233 100644
--- a/TAO/orbsvcs/tests/EC_Mcast/EC_Mcast.h
+++ b/TAO/orbsvcs/tests/EC_Mcast/EC_Mcast.h
@@ -221,13 +221,13 @@ public:
void open (const char* name,
RtecEventChannelAdmin::EventChannel_ptr event_channel,
- ACE_RANDR_TYPE &seed);
+ unsigned int *seed);
// This method connects the consumer to the EC.
void close (void);
// Disconnect from the EC.
- void connect (ACE_RANDR_TYPE& seed);
+ void connect (unsigned int *seed);
void disconnect (void);
// Disconnect from the supplier, but do not forget about it or close
// it.
@@ -357,7 +357,7 @@ private:
// @@ TODO Eventually we may need several of this objects to handle
// OS limitations on the number of multicast groups per socket.
- ACE_RANDR_TYPE seed_;
+ unsigned int seed_;
// The seed for a random number generator.
CORBA::ULong subscription_change_period_;