aboutsummaryrefslogtreecommitdiffstats
path: root/asterisk.c
diff options
context:
space:
mode:
authorcitats <citats@f38db490-d61c-443f-a65b-d21fe96a405b>2004-10-01 18:35:35 +0000
committercitats <citats@f38db490-d61c-443f-a65b-d21fe96a405b>2004-10-01 18:35:35 +0000
commitb201da1a3eb1cae654cdd3fe89ef8f9e55dd0b83 (patch)
tree528ca9766d07a87ed977dcbfd58ba8459cb4e710 /asterisk.c
parent447c7ddf201d6c90fd79a05fcc6b8302465d8524 (diff)
Fix some formatting in asterisk.c
git-svn-id: http://svn.digium.com/svn/asterisk/trunk@3872 f38db490-d61c-443f-a65b-d21fe96a405b
Diffstat (limited to 'asterisk.c')
-rwxr-xr-xasterisk.c18
1 files changed, 10 insertions, 8 deletions
diff --git a/asterisk.c b/asterisk.c
index 30740cd59..cbf9ca017 100755
--- a/asterisk.c
+++ b/asterisk.c
@@ -669,10 +669,11 @@ static void console_verboser(const char *s, int pos, int replace, int complete)
else
fputs(s + pos,stdout);
fflush(stdout);
- if (complete)
- /* Wake up a poll()ing console */
+ if (complete) {
+ /* Wake up a poll()ing console */
if (option_console && consolethread != AST_PTHREADT_NULL)
pthread_kill(consolethread, SIGURG);
+ }
}
static int ast_all_zeros(char *s)
@@ -1169,7 +1170,8 @@ static int ast_cli_display_match_list(char **matches, int len, int max)
continue;
}
- numoutput++; numoutputline++;
+ numoutput++;
+ numoutputline++;
fprintf(stdout, "%-*s ", max, matches[idx]);
free(matches[idx]);
matches[idx] = NULL;
@@ -1247,7 +1249,7 @@ static char *cli_complete(EditLine *el, int ch)
matches = (char **) NULL;
- } else {
+ } else {
nummatches = ast_cli_generatornummatches((char *)lf->buffer,ptr);
matches = ast_cli_completion_matches((char *)lf->buffer,ptr);
@@ -1538,7 +1540,7 @@ static void ast_readconfig(void) {
}
v = ast_variable_browse(cfg, "options");
while(v) {
- if(!strcasecmp(v->name, "verbose")) {
+ if (!strcasecmp(v->name, "verbose")) {
option_verbose= atoi(v->value);
} else if (!strcasecmp(v->name, "debug")) {
option_debug= ast_true(v->value);
@@ -1590,7 +1592,7 @@ int main(int argc, char *argv[])
_argv[x] = NULL;
/* if the progname is rasterisk consider it a remote console */
- if ( argv[0] && (strstr(argv[0], "rasterisk")) != NULL) {
+ if (argv[0] && (strstr(argv[0], "rasterisk")) != NULL) {
option_remote++;
option_nofork++;
}
@@ -1894,8 +1896,8 @@ int main(int argc, char *argv[])
set_icon("Asterisk");
snprintf(title, sizeof(title), "Asterisk Console on '%s' (pid %d)", hostname, ast_mainpid);
set_title(title);
- ast_cli_register(&quit);
- ast_cli_register(&astexit);
+ ast_cli_register(&quit);
+ ast_cli_register(&astexit);
for (;;) {
buf = (char *)el_gets(el, &num);