[Asterisk-code-review] Fix processing of asterisk.conf debug=yes. (asterisk[11])

Corey Farrell asteriskteam at digium.com
Tue May 12 01:50:16 CDT 2015


Corey Farrell has uploaded a new change for review.

  https://gerrit.asterisk.org/437

Change subject: Fix processing of asterisk.conf debug=yes.
......................................................................

Fix processing of asterisk.conf debug=yes.

The code which reads asterisk.conf supports processing the debug
option with ast_true, but ast_true returns -1.  Convert to 1.

ASTERISK-25042
Reported by: Corey Farrell

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


  git pull ssh://gerrit.asterisk.org:29418/asterisk refs/changes/37/437/1

diff --git a/main/asterisk.c b/main/asterisk.c
index ea01118..ba5ac18 100644
--- a/main/asterisk.c
+++ b/main/asterisk.c
@@ -3350,7 +3350,7 @@
 		} else if (!strcasecmp(v->name, "debug")) {
 			option_debug = 0;
 			if (sscanf(v->value, "%30d", &option_debug) != 1) {
-				option_debug = ast_true(v->value);
+				option_debug = ast_true(v->value) ? 1 : 0;
 			}
 #if HAVE_WORKING_FORK
 		/* Disable forking (-f at startup) */

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

Gerrit-MessageType: newchange
Gerrit-Change-Id: I3c898b7d082d914b057e111b9357fde46bad9ed6
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