diff options
author | Russell Bryant <russell@russellbryant.com> | 2005-11-30 05:29:36 +0000 |
---|---|---|
committer | Russell Bryant <russell@russellbryant.com> | 2005-11-30 05:29:36 +0000 |
commit | cff32c9b6d894d5cf9edbf73ef74c545f2d5b42d (patch) | |
tree | 7d89e11a6a537a599aa1495fe74c2a06a18bc731 /apps | |
parent | 6a2bb9c3e064ef18c00cbb515ebdabcf368842e1 (diff) |
print an error message if invalid arguments are specified (issue #5872)
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@7230 65c4cc65-6c06-0410-ace0-fbb531ad65f3
Diffstat (limited to 'apps')
-rw-r--r-- | apps/app_cut.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/apps/app_cut.c b/apps/app_cut.c index 87654fd24..b6b457ab7 100644 --- a/apps/app_cut.c +++ b/apps/app_cut.c @@ -252,6 +252,8 @@ static int cut_internal(struct ast_channel *chan, char *data, char *buffer, size } } } + } else { + return ERROR_NOARG; } return 0; } @@ -385,7 +387,7 @@ static char *acf_cut_exec(struct ast_channel *chan, char *cmd, char *data, char switch (cut_internal(chan, data, buf, len)) { case ERROR_NOARG: - ast_log(LOG_ERROR, "Cut() requires an argument\n"); + ast_log(LOG_ERROR, "CUT() requires an argument\n"); break; case ERROR_NOMEM: ast_log(LOG_ERROR, "Out of memory\n"); |