diff options
Diffstat (limited to 'cli.c')
-rwxr-xr-x | cli.c | 2 |
1 files changed, 1 insertions, 1 deletions
@@ -801,7 +801,7 @@ static char *__ast_cli_generator(char *text, char *word, int state, int lock) matchnum++; if (matchnum > state) { /* Now, what we're supposed to return is the next word... */ - if (strlen(word)) { + if (strlen(word) && x>0) { res = e->cmda[x-1]; } else { res = e->cmda[x]; |