mirror of
https://github.com/asterisk/asterisk.git
synced 2025-09-24 14:56:58 +00:00
Rollback commit 195367.
The CLI command 'manager show command' supports passing multiple AMI actions at a time. The issue with this command was in another place. git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@195368 65c4cc65-6c06-0410-ace0-fbb531ad65f3
This commit is contained in:
@@ -612,22 +612,17 @@ static char *handle_showmancmd(struct ast_cli_entry *e, int cmd, struct ast_cli_
|
|||||||
" Shows the detailed description for a specific Asterisk manager interface command.\n";
|
" Shows the detailed description for a specific Asterisk manager interface command.\n";
|
||||||
return NULL;
|
return NULL;
|
||||||
case CLI_GENERATE:
|
case CLI_GENERATE:
|
||||||
if (a->pos == 3) {
|
l = strlen(a->word);
|
||||||
/* autocomplete the action name. */
|
which = 0;
|
||||||
l = strlen(a->word);
|
AST_RWLIST_RDLOCK(&actions);
|
||||||
which = 0;
|
AST_RWLIST_TRAVERSE(&actions, cur, list) {
|
||||||
AST_RWLIST_RDLOCK(&actions);
|
if (!strncasecmp(a->word, cur->action, l) && ++which > a->n) {
|
||||||
AST_RWLIST_TRAVERSE(&actions, cur, list) {
|
ret = ast_strdup(cur->action);
|
||||||
if (!strncasecmp(a->word, cur->action, l) && ++which > a->n) {
|
break; /* make sure we exit even if ast_strdup() returns NULL */
|
||||||
ret = ast_strdup(cur->action);
|
|
||||||
break; /* make sure we exit even if ast_strdup() returns NULL */
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
AST_RWLIST_UNLOCK(&actions);
|
|
||||||
return ret;
|
|
||||||
}
|
}
|
||||||
|
AST_RWLIST_UNLOCK(&actions);
|
||||||
return NULL;
|
return ret;
|
||||||
}
|
}
|
||||||
authority = ast_str_alloca(80);
|
authority = ast_str_alloca(80);
|
||||||
if (a->argc != 4) {
|
if (a->argc != 4) {
|
||||||
|
Reference in New Issue
Block a user