aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorkpfleming <kpfleming@f38db490-d61c-443f-a65b-d21fe96a405b>2005-11-10 23:18:03 +0000
committerkpfleming <kpfleming@f38db490-d61c-443f-a65b-d21fe96a405b>2005-11-10 23:18:03 +0000
commitd6e2d41e4ec60d28dc618283ef500df39a39cd9c (patch)
treef982880a71656821fbbcc701db96d258d4da9a8b
parentdc51c798ce6c8acd3ae711075349d91c2fe436df (diff)
slight correction to options parsing
git-svn-id: http://svn.digium.com/svn/asterisk/trunk@7052 f38db490-d61c-443f-a65b-d21fe96a405b
-rwxr-xr-xChangeLog4
-rwxr-xr-xapp.c2
2 files changed, 4 insertions, 2 deletions
diff --git a/ChangeLog b/ChangeLog
index b7b4f229f..27b3230f0 100755
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,10 +1,12 @@
2005-11-10 Kevin P. Fleming <kpfleming@digium.com>
+ * app.c (ast_app_parse_options): don't increment 's' until after checking for NULL (related to issue #5630)
+
* apps/app_rpt.c: solve a memory leak (config structure was not freed) (issue #5706
2005-11-10 Russell Bryant <russell@digium.com>
- * app.c (ast_app_separate_args): Don't consider the open parenthesis as part of the arguments to an option.
+ * app.c (ast_app_separate_args): Don't consider the open parenthesis as part of the arguments to an option. (issue #5630)
* many files: Change all references to ast_separate_app_args to ast_app_separate_args
* many files in apps/: Clean up some application descriptions. Make sure all descriptions in changed files are wrapped at 80 characters.
diff --git a/app.c b/app.c
index 63beed1e3..bcb5c2259 100755
--- a/app.c
+++ b/app.c
@@ -1544,7 +1544,7 @@ int ast_app_parse_options(const struct ast_app_option *options, struct ast_flags
if (*s == '(') {
/* Has argument */
arg = ++s;
- while (*++s && (*s != ')'));
+ while (*s && (*s++ != ')'));
if (*s) {
if (argloc)
args[argloc - 1] = arg;