[Asterisk-code-review] logger: Fix default console settings. (asterisk[11])

Corey Farrell asteriskteam at digium.com
Tue Sep 20 10:09:31 CDT 2016


Corey Farrell has uploaded a new change for review.

  https://gerrit.asterisk.org/3930

Change subject: logger: Fix default console settings.
......................................................................

logger: Fix default console settings.

When logger.conf is missing or invalid we should be printing notices,
warnings and errors to the console.  The logmask was incorrectly
calculated.

Change-Id: Ibaa9465a8682854bc1a5e9ba07079bea1bfb6bb3
---
M main/logger.c
1 file changed, 1 insertion(+), 1 deletion(-)


  git pull ssh://gerrit.asterisk.org:29418/asterisk refs/changes/30/3930/1

diff --git a/main/logger.c b/main/logger.c
index 1424352..3baca14 100644
--- a/main/logger.c
+++ b/main/logger.c
@@ -414,7 +414,7 @@
 			return -1;
 		}
 		chan->type = LOGTYPE_CONSOLE;
-		chan->logmask = __LOG_WARNING | __LOG_NOTICE | __LOG_ERROR;
+		chan->logmask = (1 << __LOG_WARNING) | (1 << __LOG_NOTICE | (1 << __LOG_ERROR);
 
 		if (!locked) {
 			AST_RWLIST_WRLOCK(&logchannels);

-- 
To view, visit https://gerrit.asterisk.org/3930
To unsubscribe, visit https://gerrit.asterisk.org/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: Ibaa9465a8682854bc1a5e9ba07079bea1bfb6bb3
Gerrit-PatchSet: 1
Gerrit-Project: asterisk
Gerrit-Branch: 11
Gerrit-Owner: Corey Farrell <git at cfware.com>



More information about the asterisk-code-review mailing list