[svn-commits] file: branch 1.6.0 r117087 - in /branches/1.6.0: ./ main/logger.c

SVN commits to the Digium repositories svn-commits at lists.digium.com
Mon May 19 11:05:25 CDT 2008


Author: file
Date: Mon May 19 11:05:25 2008
New Revision: 117087

URL: http://svn.digium.com/view/asterisk?view=rev&rev=117087
Log:
Merged revisions 117085 via svnmerge from 
https://origsvn.digium.com/svn/asterisk/trunk

........
r117085 | file | 2008-05-19 13:03:33 -0300 (Mon, 19 May 2008) | 4 lines

The logger closes the files it is logging to when reloading so we have to read in the logger configuration even if it has not changed so that the logs get opened again.
(closes issue #12665)
Reported by: DennisD

........

Modified:
    branches/1.6.0/   (props changed)
    branches/1.6.0/main/logger.c

Propchange: branches/1.6.0/
------------------------------------------------------------------------------
Binary property 'trunk-merged' - no diff available.

Modified: branches/1.6.0/main/logger.c
URL: http://svn.digium.com/view/asterisk/branches/1.6.0/main/logger.c?view=diff&rev=117087&r1=117086&r2=117087
==============================================================================
--- branches/1.6.0/main/logger.c (original)
+++ branches/1.6.0/main/logger.c Mon May 19 11:05:25 2008
@@ -317,15 +317,15 @@
 	return chan;
 }
 
-static void init_logger_chain(int reload, int locked)
+static void init_logger_chain(int locked)
 {
 	struct logchannel *chan;
 	struct ast_config *cfg;
 	struct ast_variable *var;
 	const char *s;
-	struct ast_flags config_flags = { reload ? CONFIG_FLAG_FILEUNCHANGED : 0 };
-
-	if ((cfg = ast_config_load("logger.conf", config_flags)) == CONFIG_STATUS_FILEUNCHANGED)
+	struct ast_flags config_flags = { 0 };
+
+	if (!(cfg = ast_config_load("logger.conf", config_flags)))
 		return;
 
 	/* delete our list of log channels */
@@ -592,7 +592,7 @@
 
 	filesize_reload_needed = 0;
 
-	init_logger_chain(rotate ? 0 : 1 /* reload */, 1 /* locked */);
+	init_logger_chain(1 /* locked */);
 
 	if (logfiles.event_log) {
 		snprintf(old, sizeof(old), "%s/%s", ast_config_AST_LOG_DIR, EVENTLOG);
@@ -927,7 +927,7 @@
 	ast_mkdir(ast_config_AST_LOG_DIR, 0777);
   
 	/* create log channels */
-	init_logger_chain(0 /* reload */, 0 /* locked */);
+	init_logger_chain(0 /* locked */);
 
 	/* create the eventlog */
 	if (logfiles.event_log) {




More information about the svn-commits mailing list