From 803a9203d5a4a5c67d4f332d636a04c84dd9f849 Mon Sep 17 00:00:00 2001 From: Sean Bright Date: Wed, 14 Jan 2009 23:10:48 +0000 Subject: Don't crash when typing 'core set verbose' or 'core set debug' by themselves. (closes issue #14219) Reported by: jamesgolovich Patches: asterisk-setverbosecrash.diff.txt uploaded by jamesgolovich (license 176) git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@168626 65c4cc65-6c06-0410-ace0-fbb531ad65f3 --- main/cli.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'main/cli.c') diff --git a/main/cli.c b/main/cli.c index 57f936b09..d04124429 100644 --- a/main/cli.c +++ b/main/cli.c @@ -415,7 +415,7 @@ static char *handle_verbose(struct ast_cli_entry *e, int cmd, struct ast_cli_arg * we are guaranteed to be called with argc >= e->args; */ - if (argc < e->args) + if (argc <= e->args) return CLI_SHOWUSAGE; if (!strcasecmp(argv[e->args - 1], "debug")) { dst = &option_debug; -- cgit v1.2.3