summaryrefslogtreecommitdiff
path: root/main/asterisk.c
diff options
context:
space:
mode:
authorJeff Peeler <jpeeler@digium.com>2009-01-03 20:29:54 +0000
committerJeff Peeler <jpeeler@digium.com>2009-01-03 20:29:54 +0000
commit334a89f7546ed7689e986d465833e84cbdc2f2d0 (patch)
tree19b05f26baee694bf7c0b0f06b44fa5d77299aea /main/asterisk.c
parente1f941d7f685bd1e47e6ad407296ffbe003690f8 (diff)
When parsing environment variable ASTERISK_PROMPT, make sure to proceed to the next character when a non format specifier is used (no %). Otherwise, the while loop looking for the null byte will never exit.
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@167125 65c4cc65-6c06-0410-ace0-fbb531ad65f3
Diffstat (limited to 'main/asterisk.c')
-rw-r--r--main/asterisk.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/main/asterisk.c b/main/asterisk.c
index 2b3832a4d..ccacc6aa6 100644
--- a/main/asterisk.c
+++ b/main/asterisk.c
@@ -2235,10 +2235,10 @@ static char *cli_prompt(EditLine *editline)
t--;
break;
}
- t++;
} else {
ast_str_append(&prompt, 0, "%c", *t);
}
+ t++;
}
if (color_used) {
/* Force colors back to normal at end */