]> git.ipfire.org Git - thirdparty/asterisk.git/commitdiff
Merged revisions 228015 via svnmerge from
authorTilghman Lesher <tilghman@meg.abyt.es>
Thu, 5 Nov 2009 17:10:06 +0000 (17:10 +0000)
committerTilghman Lesher <tilghman@meg.abyt.es>
Thu, 5 Nov 2009 17:10:06 +0000 (17:10 +0000)
https://origsvn.digium.com/svn/asterisk/trunk

........
  r228015 | tilghman | 2009-11-05 11:08:02 -0600 (Thu, 05 Nov 2009) | 4 lines

  Don't crash if no arguments are passed.
  (closes issue #16119)
   Reported by: thedavidfactor
........

git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.6.1@228016 65c4cc65-6c06-0410-ace0-fbb531ad65f3

apps/app_externalivr.c

index d7f51e00906ce37a94f016088dfa86e696502551..e3e866c8f35cabd194ae813eb800a109706188ae 100644 (file)
@@ -349,6 +349,11 @@ static int app_exec(struct ast_channel *chan, void *data)
        u->abort_current_sound = 0;
        u->chan = chan;
 
+       if (ast_strlen_zero(data)) {
+               ast_log(LOG_WARNING, "ExternalIVR requires a command to execute\n");
+               return -1;
+       }
+
        buf = ast_strdupa(data);
        AST_STANDARD_APP_ARGS(eivr_args, buf);