Skip to content
Snippets Groups Projects
Commit 2204f89a authored by Tilghman Lesher's avatar Tilghman Lesher
Browse files

Merged revisions 235052 via svnmerge from

https://origsvn.digium.com/svn/asterisk/branches/1.4

........
  r235052 | tilghman | 2009-12-15 09:29:24 -0600 (Tue, 15 Dec 2009) | 4 lines
  
  Mandatory argument checking
  (closes issue #16446)
   Reported by: nicchap
........


git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@235053 65c4cc65-6c06-0410-ace0-fbb531ad65f3
parent df1fc1f3
Branches
Tags
No related merge requests found
...@@ -2553,6 +2553,9 @@ static int handle_noop(struct ast_channel *chan, AGI *agi, int arg, const char * ...@@ -2553,6 +2553,9 @@ static int handle_noop(struct ast_channel *chan, AGI *agi, int arg, const char *
static int handle_setmusic(struct ast_channel *chan, AGI *agi, int argc, const char * const argv[]) static int handle_setmusic(struct ast_channel *chan, AGI *agi, int argc, const char * const argv[])
{ {
if (argc < 3) {
return RESULT_SHOWUSAGE;
}
if (!strncasecmp(argv[2], "on", 2)) if (!strncasecmp(argv[2], "on", 2))
ast_moh_start(chan, argc > 3 ? argv[3] : NULL, NULL); ast_moh_start(chan, argc > 3 ? argv[3] : NULL, NULL);
else if (!strncasecmp(argv[2], "off", 3)) else if (!strncasecmp(argv[2], "off", 3))
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment