diff options
author | iliyan <iliyan@ae88bc3d-4319-0410-8dbf-d08b4c9d3795> | 2008-03-27 21:04:48 +0000 |
---|---|---|
committer | iliyan <iliyan@ae88bc3d-4319-0410-8dbf-d08b4c9d3795> | 2008-03-27 21:04:48 +0000 |
commit | 700e58c3a27eb515537a065ab0f815456e5a81c2 (patch) | |
tree | 61930d6c379b0c322799a40ccd9573b82bc28a54 | |
parent | 63248aae4174f479156746a41ecd5b596f540a1a (diff) | |
download | ATCD-700e58c3a27eb515537a065ab0f815456e5a81c2.tar.gz |
ChangeLogTag: Thu Mar 27 21:04:11 UTC 2008 Iliyan Jeliazkov <iliyan@ociweb.com>
-rw-r--r-- | ACE/ChangeLog.iliyan-gestalt | 11 | ||||
-rw-r--r-- | ACE/THANKS | 1 | ||||
-rw-r--r-- | ACE/ace/Service_Gestalt.cpp | 63 |
3 files changed, 44 insertions, 31 deletions
diff --git a/ACE/ChangeLog.iliyan-gestalt b/ACE/ChangeLog.iliyan-gestalt index ee970cde1b6..777b8e7d1a1 100644 --- a/ACE/ChangeLog.iliyan-gestalt +++ b/ACE/ChangeLog.iliyan-gestalt @@ -1,9 +1,18 @@ +Thu Mar 27 21:04:11 UTC 2008 Iliyan Jeliazkov <iliyan@ociweb.com> + + * THANKS: + * ace/Service_Gestalt.cpp: + + Adding the patch suggested in bug# 3007. Thanks to Michael Carter + <mcarter at swri dot org> for reporting and debugging. + Thu Mar 27 13:42:23 UTC 2008 Iliyan Jeliazkov <iliyan@ociweb.com> * ace/Service_Config.h: Replacing the use of a "magic" number for the service repository - size with the appropriate #define + size with the appropriate # + define * ace/String_Base.cpp: diff --git a/ACE/THANKS b/ACE/THANKS index d3bb99f2bd5..7750e83d1b4 100644 --- a/ACE/THANKS +++ b/ACE/THANKS @@ -2238,6 +2238,7 @@ Nayeem Khan <d dot nayeem dot khan at gmail dot com> Sorin Voicu-Comendant <sorinvc at gmail dot com> Andi Heusser <aheusser at gmail dot com> Paul Carter <pcarter at scires dot com> +Michael Carter <mcarter at swri dot org> I would particularly like to thank Paul Stephenson, who worked with me at Ericsson in the early 1990's. Paul devised the recursive Makefile diff --git a/ACE/ace/Service_Gestalt.cpp b/ACE/ace/Service_Gestalt.cpp index b2b2abf9340..e97e7318616 100644 --- a/ACE/ace/Service_Gestalt.cpp +++ b/ACE/ace/Service_Gestalt.cpp @@ -535,8 +535,8 @@ ACE_Service_Gestalt::initialize (const ACE_Service_Type_Factory *stf, #ifndef ACE_NLOGGING if (ACE::debug ()) ACE_DEBUG ((LM_DEBUG, - ACE_TEXT ("ACE (%P|%t) SG::initialize - repo=%@, looking up dynamic ") - ACE_TEXT ("service \'%s\' to initialize\n"), + ACE_TEXT ("ACE (%P|%t) SG::initialize - repo=%@, name=%s") + ACE_TEXT (" - looking up in the repo\n"), this->repo_, stf->name ())); #endif @@ -545,23 +545,19 @@ ACE_Service_Gestalt::initialize (const ACE_Service_Type_Factory *stf, int const retv = this->repo_->find (stf->name (), (const ACE_Service_Type **) &srp); - // If there is an active service already, it must first be removed, - // before it could be re-installed. - // IJ: This used to be the behavior, before allowing multiple - // independent service repositories. Should that still be required? + // If there is an active service already, remove it first + // before it can be re-installed. if (retv >= 0) { #ifndef ACE_NLOGGING if (ACE::debug ()) - ACE_ERROR_RETURN ((LM_WARNING, - ACE_TEXT ("ACE (%P|%t) SG::initialize - repo=%@,") - ACE_TEXT (" %s is already initialized.") - ACE_TEXT (" Remove before re-initializing.\n"), - this->repo_, - stf->name ()), - 0); + ACE_DEBUG ((LM_WARNING, + ACE_LIB_TEXT ("ACE (%P|%t) SG::initialize - repo=%@,") + ACE_LIB_TEXT (" name=%s - removing a pre-existing namesake.\n"), + this->repo_, + stf->name ())); #endif - return 0; + this->repo_->remove (stf->name ()); } // If there is an inactive service by that name it may have been @@ -577,9 +573,9 @@ ACE_Service_Gestalt::initialize (const ACE_Service_Type_Factory *stf, if (retv == -2 && srp->type () == 0) ACE_ERROR_RETURN ((LM_WARNING, ACE_TEXT ("ACE (%P|%t) SG::initialize - repo=%@,") - ACE_TEXT (" %s is forward-declared.") - ACE_TEXT (" Recursive initialization requests are") - ACE_TEXT (" not supported.\n"), + ACE_TEXT (" name=%s - forward-declared; ") + ACE_TEXT (" recursive initialization requests are") + ACE_TEXT (" ignored.\n"), this->repo_, stf->name ()), -1); @@ -633,19 +629,24 @@ ACE_Service_Gestalt::initialize (const ACE_Service_Type *sr, if (ACE::debug ()) ACE_DEBUG ((LM_DEBUG, - ACE_TEXT ("ACE (%P|%t) SG::initialize - looking up dynamic ") - ACE_TEXT (" service %s to initialize, repo=%@\n"), - sr->name (), this->repo_)); + ACE_TEXT ("ACE (%P|%t) SG::initialize - repo=%@, name=%s") + ACE_TEXT (" - looking up in the repo\n"), + this->repo_, + sr->name ())); ACE_Service_Type *srp = 0; if (this->repo_->find (sr->name (), (const ACE_Service_Type **) &srp) >= 0) - ACE_ERROR_RETURN ((LM_WARNING, - ACE_TEXT ("ACE (%P|%t) SG::initialize - \'%s\' ") - ACE_TEXT ("has already been installed. ") - ACE_TEXT ("Remove before reinstalling\n"), - sr->name ()), - 0); + { +#ifndef ACE_NLOGGING + ACE_DEBUG ((LM_WARNING, + ACE_LIB_TEXT ("ACE (%P|%t) SG::initialize - repo=%@, name=%s") + ACE_LIB_TEXT (" - removing a pre-existing namesake.\n"), + this->repo_, + sr->name ())); +#endif + this->repo_->remove (sr->name ()); + } return this->initialize_i (sr, parameters); @@ -670,8 +671,9 @@ ACE_Service_Gestalt::initialize_i (const ACE_Service_Type *sr, // Not using LM_ERROR here to avoid confusing the test harness if (ACE::debug ()) ACE_ERROR_RETURN ((LM_WARNING, - ACE_TEXT ("ACE (%P|%t) SG::initialize_i ") - ACE_TEXT ("failed for %s: %m\n"), + ACE_TEXT ("ACE (%P|%t) SG::initialize_i -") + ACE_TEXT (" repo=%@, name=%s - remove failed: %m\n"), + this->repo_, sr->name ()), -1); #endif @@ -684,8 +686,9 @@ ACE_Service_Gestalt::initialize_i (const ACE_Service_Type *sr, // Not using LM_ERROR here to avoid confusing the test harness if (ACE::debug ()) ACE_ERROR_RETURN ((LM_WARNING, - ACE_TEXT ("ACE (%P|%t) SG - repository insert ") - ACE_TEXT ("failed for %s: %m\n"), + ACE_TEXT ("ACE (%P|%t) SG::initialize_i -") + ACE_TEXT (" repo=%@, name=%s - insert failed: %m\n"), + this->repo_, sr->name ()), -1); #endif |