- added new logging context for configuration manager
authorJan Hutter <jhutter@hsr.ch>
Tue, 22 Nov 2005 11:55:57 +0000 (11:55 -0000)
committerJan Hutter <jhutter@hsr.ch>
Tue, 22 Nov 2005 11:55:57 +0000 (11:55 -0000)
Source/charon/utils/logger_manager.c
Source/charon/utils/logger_manager.h

index 0470e7a..0601eae 100644 (file)
@@ -41,6 +41,7 @@ mapping_t logger_context_t_mappings[] = {
        {SOCKET, "SOCKET"},
        {TESTER, "TESTER"},
        {DAEMON, "DAEMON"},
+       {CONFIGURATION_MANAGER, "CONFIG"},
 };
 
 /** 
@@ -394,6 +395,7 @@ static status_t disable_logger_level (private_logger_manager_t *this, logger_con
  */
 static status_t destroy(private_logger_manager_t *this)
 {
+
        while (this->loggers->get_count(this->loggers) > 0)
        {
                loggers_entry_t *current_entry;
@@ -404,7 +406,7 @@ static status_t destroy(private_logger_manager_t *this)
                current_entry->logger->destroy(current_entry->logger);
                
                /* entry can be destroyed */
-               allocator_free(current_entry);          
+               allocator_free(current_entry);  
        }
        
        while (this->logger_levels->get_count(this->logger_levels) > 0)
index 2bd3059..04fca23 100644 (file)
@@ -46,6 +46,7 @@ enum logger_context_e{
        SOCKET,
        TESTER,
        DAEMON,
+       CONFIGURATION_MANAGER,
        };
 
 /**
@@ -67,7 +68,7 @@ struct logger_manager_s {
         * @param context               logger_context to use the logger for.
         * @param[out] logger   pointer to a a place where the new logger is stored
         * @param name                  name for the new logger. Context name is already included 
-        *                                              and has not to be specified.
+        *                                              and has not to be specified (so NULL is allowed).
         * @return
         *                                              - logger_t on SUCCESS
         *                                              - NULL otherwise