summaryrefslogtreecommitdiff
path: root/ace/Service_Config.cpp
diff options
context:
space:
mode:
authorbrunsch <brunsch@ae88bc3d-4319-0410-8dbf-d08b4c9d3795>1998-05-18 17:31:15 +0000
committerbrunsch <brunsch@ae88bc3d-4319-0410-8dbf-d08b4c9d3795>1998-05-18 17:31:15 +0000
commitc88c3603c2a7b141d34ba839fd3ce3408cb055fc (patch)
treeeccd4efaecb7048f3bca605e7aa438fb886bf128 /ace/Service_Config.cpp
parentb3aae5ab0f9063391befdd4ea8fac07afb398e12 (diff)
downloadATCD-c88c3603c2a7b141d34ba839fd3ce3408cb055fc.tar.gz
Changed Service Configurator so debug messages are only outputted when a
debug flag is used.
Diffstat (limited to 'ace/Service_Config.cpp')
-rw-r--r--ace/Service_Config.cpp12
1 files changed, 8 insertions, 4 deletions
diff --git a/ace/Service_Config.cpp b/ace/Service_Config.cpp
index e99153b6a1f..a2730e2debc 100644
--- a/ace/Service_Config.cpp
+++ b/ace/Service_Config.cpp
@@ -268,7 +268,8 @@ ACE_Service_Config::initialize (const ASYS_TCHAR svc_name[],
ACE_ARGV args (parameters);
ACE_Service_Type *srp = 0;
- ACE_DEBUG ((LM_DEBUG, ASYS_TEXT ("opening static service %s\n"), svc_name));
+ if (ACE_Service_Config::debug_)
+ ACE_DEBUG ((LM_DEBUG, ASYS_TEXT ("opening static service %s\n"), svc_name));
if (ACE_Service_Repository::instance ()->find (svc_name,
(const ACE_Service_Type **) &srp) == -1)
@@ -294,7 +295,8 @@ ACE_Service_Config::initialize (const ACE_Service_Type *sr,
ACE_TRACE ("ACE_Service_Config::initialize");
ACE_ARGV args (parameters);
- ACE_DEBUG ((LM_DEBUG, ASYS_TEXT ("opening dynamic service %s\n"), sr->name ()));
+ if (ACE_Service_Config::debug_)
+ ACE_DEBUG ((LM_DEBUG, ASYS_TEXT ("opening dynamic service %s\n"), sr->name ()));
if (ACE_Service_Repository::instance ()->insert (sr) == -1)
ACE_ERROR_RETURN ((LM_ERROR, ASYS_TEXT ("insertion failed, %p\n"), sr->name ()), -1);
@@ -482,7 +484,8 @@ ACE_Service_Config::open (const ASYS_TCHAR program_name[],
return -1;
else
{
- ACE_DEBUG ((LM_STARTUP, ASYS_TEXT ("starting up daemon %n\n")));
+ if (ACE_Service_Config::debug_)
+ ACE_DEBUG ((LM_STARTUP, ASYS_TEXT ("starting up daemon %n\n")));
// Initialize the Service Repository (this will still work if
// user forgets to define an object of type ACE_Service_Config).
@@ -546,7 +549,8 @@ ACE_Service_Config::reconfigure (void)
if (ACE_Service_Config::debug_)
{
time_t t = ACE_OS::time (0);
- ACE_DEBUG ((LM_DEBUG, ASYS_TEXT ("beginning reconfiguration at %s"), ACE_OS::ctime (&t)));
+ if (ACE_Service_Config::debug_)
+ ACE_DEBUG ((LM_DEBUG, ASYS_TEXT ("beginning reconfiguration at %s"), ACE_OS::ctime (&t)));
}
if (ACE_Service_Config::process_directives () == -1)