diff options
author | rizzo <rizzo@f38db490-d61c-443f-a65b-d21fe96a405b> | 2006-05-01 00:02:12 +0000 |
---|---|---|
committer | rizzo <rizzo@f38db490-d61c-443f-a65b-d21fe96a405b> | 2006-05-01 00:02:12 +0000 |
commit | eac1edd58fa7d858549648dcdf32b414a14c1d17 (patch) | |
tree | af790c9eecd3756e40ce0f23160e0411cd351297 /pbx/ael/ael.y | |
parent | e3c71666ddc003e7e0a03531e4516bd859b3f8c6 (diff) |
fix dereferencing freed memory
git-svn-id: http://svn.digium.com/svn/asterisk/trunk@23795 f38db490-d61c-443f-a65b-d21fe96a405b
Diffstat (limited to 'pbx/ael/ael.y')
-rw-r--r-- | pbx/ael/ael.y | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/pbx/ael/ael.y b/pbx/ael/ael.y index 51561a651..1ce724cda 100644 --- a/pbx/ael/ael.y +++ b/pbx/ael/ael.y @@ -569,12 +569,13 @@ macro_call : word LP {reset_argcount(parseio->scanner);} eval_arglist RP { */ application_call_head: word LP {reset_argcount(parseio->scanner);} { if (strcasecmp($1,"goto") == 0) { - $$= npval2(PV_GOTO, &@1, &@3); + $$ = npval2(PV_GOTO, &@1, &@2); free($1); /* won't be using this */ ast_log(LOG_WARNING, "==== File: %s, Line %d, Cols: %d-%d: Suggestion: Use the goto statement instead of the Goto() application call in AEL.\n", my_file, @1.first_line, @1.first_column, @1.last_column ); - } else - $$= npval2(PV_APPLICATION_CALL, &@1, &@3); - $$->u1.str = $1; } + } else { + $$= npval2(PV_APPLICATION_CALL, &@1, &@2); + $$->u1.str = $1; + } } ; application_call : application_call_head eval_arglist RP { |