summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAngelo Corsaro <angelo@icorsaro.net>2000-10-12 05:15:04 +0000
committerAngelo Corsaro <angelo@icorsaro.net>2000-10-12 05:15:04 +0000
commit3880019ef293b4facc4783441a6dfcf1fb611ccc (patch)
tree876c7a67faf1a4d437adddf84f0c9785f9f34371
parent593e402e376124475367676f8a5e9885592cee46 (diff)
downloadATCD-3880019ef293b4facc4783441a6dfcf1fb611ccc.tar.gz
ChangeLogTag: Thu Oct 12 00:07:36 2000 Angelo Corsaro <corsaro@cs.wustl.edu>
-rw-r--r--TAO/ChangeLogs/ChangeLog-02a8
-rw-r--r--TAO/tao/MProfile.cpp12
2 files changed, 15 insertions, 5 deletions
diff --git a/TAO/ChangeLogs/ChangeLog-02a b/TAO/ChangeLogs/ChangeLog-02a
index 7bb8cd10169..ffc0711b0d3 100644
--- a/TAO/ChangeLogs/ChangeLog-02a
+++ b/TAO/ChangeLogs/ChangeLog-02a
@@ -1,3 +1,11 @@
+Thu Oct 12 00:07:36 2000 Angelo Corsaro <corsaro@cs.wustl.edu>
+
+ * tao/MProfile.cpp:
+
+ Fixed problem with double checked locking. Thanks to Marina
+ for noting that.
+
+
Wed Oct 11 23:12:03 2000 Angelo Corsaro <corsaro@cs.wustl.edu>
* tao/PortableServer/Strategized_Object_Proxy_Broker.cpp:
diff --git a/TAO/tao/MProfile.cpp b/TAO/tao/MProfile.cpp
index 3adf244f6c9..8808536b66a 100644
--- a/TAO/tao/MProfile.cpp
+++ b/TAO/tao/MProfile.cpp
@@ -233,16 +233,18 @@ TAO_MProfile::init_policy_list (void)
CORBA::PolicyList*
TAO_MProfile::policy_list (void)
{
- if (this->is_policy_list_initialized_)
- return this->policy_list_;
- else
+ if (!this->is_policy_list_initialized_)
{
ACE_GUARD_RETURN (ACE_SYNCH_RECURSIVE_MUTEX,
guard,
this->mutex_,
0);
- this->create_policy_list ();
- this->init_policy_list ();
+
+ if (this->policy_list_ == 0)
+ {
+ this->create_policy_list ();
+ this->init_policy_list ();
+ }
}
return this->policy_list_;