mirror of
https://github.com/asterisk/asterisk.git
synced 2025-09-04 20:04:50 +00:00
Really initialize queue log
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@2226 65c4cc65-6c06-0410-ace0-fbb531ad65f3
This commit is contained in:
8
logger.c
8
logger.c
@@ -323,6 +323,8 @@ int reload_logger(int rotate)
|
||||
|
||||
ast_mutex_unlock(&loglock);
|
||||
|
||||
queue_log_init();
|
||||
|
||||
if (eventlog) {
|
||||
init_logger_chain();
|
||||
ast_log(LOG_EVENT, "Restarted Asterisk Event Logger\n");
|
||||
@@ -331,7 +333,6 @@ int reload_logger(int rotate)
|
||||
return 0;
|
||||
} else
|
||||
ast_log(LOG_ERROR, "Unable to create event log: %s\n", strerror(errno));
|
||||
queue_log_init();
|
||||
init_logger_chain();
|
||||
return -1;
|
||||
}
|
||||
@@ -401,6 +402,9 @@ int init_logger(void)
|
||||
ast_cli_register(&reload_logger_cli);
|
||||
ast_cli_register(&rotate_logger_cli);
|
||||
|
||||
/* initialize queue logger */
|
||||
queue_log_init();
|
||||
|
||||
/* create the eventlog */
|
||||
mkdir((char *)ast_config_AST_LOG_DIR, 0755);
|
||||
snprintf(tmp, sizeof(tmp), "%s/%s", (char *)ast_config_AST_LOG_DIR, EVENTLOG);
|
||||
@@ -418,8 +422,6 @@ int init_logger(void)
|
||||
|
||||
/* create log channels */
|
||||
init_logger_chain();
|
||||
/* initialize queue logger */
|
||||
queue_log_init();
|
||||
return -1;
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user