[asterisk-commits] pabelanger: branch pabelanger/CDRSettings r335128 - /team/pabelanger/CDRSetti...
SVN commits to the Asterisk project
asterisk-commits at lists.digium.com
Sun Sep 11 02:17:30 CDT 2011
Author: pabelanger
Date: Sun Sep 11 02:17:27 2011
New Revision: 335128
URL: http://svnview.digium.com/svn/asterisk?view=rev&rev=335128
Log:
Not sure what I was thinking
Modified:
team/pabelanger/CDRSettings/main/cdr.c
Modified: team/pabelanger/CDRSettings/main/cdr.c
URL: http://svnview.digium.com/svn/asterisk/team/pabelanger/CDRSettings/main/cdr.c?view=diff&rev=335128&r1=335127&r2=335128
==============================================================================
--- team/pabelanger/CDRSettings/main/cdr.c (original)
+++ team/pabelanger/CDRSettings/main/cdr.c Sun Sep 11 02:17:27 2011
@@ -1551,23 +1551,17 @@
for (v = ast_variable_browse(config, "general"); v; v = v->next) {
if (!strcasecmp(v->name, "enable")) {
enabled = ast_true(v->value);
- }
- if (!strcasecmp(v->name, "unanswered")) {
+ } else if (!strcasecmp(v->name, "unanswered")) {
unanswered = ast_true(v->value);
- }
- if (!strcasecmp(v->name, "congestion")) {
+ } else if (!strcasecmp(v->name, "congestion")) {
congestion = ast_true(v->value);
- }
- if (!strcasecmp(v->name, "batch")) {
+ } else if (!strcasecmp(v->name, "batch")) {
batchmode = ast_true(v->value);
- }
- if (!strcasecmp(v->name, "scheduleronly")) {
+ } else if (!strcasecmp(v->name, "scheduleronly")) {
batchscheduleronly = ast_true(v->value);
- }
- if (!strcasecmp(v->name, "safeshutdown")) {
+ } else if (!strcasecmp(v->name, "safeshutdown")) {
batchsafeshutdown = ast_true(v->value);
- }
- if (!strcasecmp(v->name, "size")) {
+ } else if (!strcasecmp(v->name, "size")) {
if (sscanf(v->value, "%30d", &cfg_size) < 1) {
ast_log(LOG_WARNING, "Unable to convert '%s' to a numeric value.\n", v->value);
} else if (cfg_size < 0) {
@@ -1575,8 +1569,7 @@
} else {
batchsize = cfg_size;
}
- }
- if (!strcasecmp(v->name, "time")) {
+ } else if (!strcasecmp(v->name, "time")) {
if (sscanf(v->value, "%30d", &cfg_time) < 1) {
ast_log(LOG_WARNING, "Unable to convert '%s' to a numeric value.\n", v->value);
} else if (cfg_time < 0) {
@@ -1584,11 +1577,9 @@
} else {
batchtime = cfg_time;
}
- }
- if (!strcasecmp(v->name, "endbeforehexten")) {
+ } else if (!strcasecmp(v->name, "endbeforehexten")) {
ast_set2_flag(&ast_options, ast_true(v->value), AST_OPT_FLAG_END_CDR_BEFORE_H_EXTEN);
- }
- if (!strcasecmp(v->name, "initiatedseconds")) {
+ } else if (!strcasecmp(v->name, "initiatedseconds")) {
ast_set2_flag(&ast_options, ast_true(v->value), AST_OPT_FLAG_INITIATED_SECONDS);
}
}
More information about the asterisk-commits
mailing list