projects
/
asterisk/asterisk.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
05e338c
)
Don't record empty lines (bug #2175, but not using proposed patch)
author
Mark Spencer
<markster@digium.com>
Sun, 1 Aug 2004 18:12:52 +0000
(18:12 +0000)
committer
Mark Spencer
<markster@digium.com>
Sun, 1 Aug 2004 18:12:52 +0000
(18:12 +0000)
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@3561
65c4cc65
-6c06-0410-ace0-
fbb531ad65f3
asterisk.c
patch
|
blob
|
history
diff --git
a/asterisk.c
b/asterisk.c
index
29a105b
..
575ddbc
100755
(executable)
--- a/
asterisk.c
+++ b/
asterisk.c
@@
-654,12
+654,22
@@
static void console_verboser(const char *s, int pos, int replace, int complete)
pthread_kill(consolethread, SIGURG);
}
+static int ast_all_zeros(char *s)
+{
+ while(*s) {
+ if (*s > 32)
+ return 0;
+ s++;
+ }
+ return 1;
+}
+
static void consolehandler(char *s)
{
printf(term_end());
fflush(stdout);
/* Called when readline data is available */
- if (s && !ast_strlen_zero(s))
+ if (s && !ast_all_zeros(s))
ast_el_add_history(s);
/* Give the console access to the shell */
if (s) {