mirror of
https://github.com/asterisk/asterisk.git
synced 2025-09-24 22:58:21 +00:00
Revert "pbx_ael: Global variables are not expanded."
This reverts commit 56051d1ac5
.
Reason for revert: Behavior change that breaks existing dialplan.
ASTERISK-30472 #close
Change-Id: I83bed3b800d36228a04ded0a6164b795f7f16bd6
This commit is contained in:
committed by
George Joseph
parent
e7f0440032
commit
6e50550d28
@@ -4414,11 +4414,7 @@ int ast_compile_ael2(struct ast_context **local_contexts, struct ast_hashtab *lo
|
|||||||
{
|
{
|
||||||
pval *p,*p2;
|
pval *p,*p2;
|
||||||
struct ast_context *context;
|
struct ast_context *context;
|
||||||
#ifdef LOW_MEMORY
|
|
||||||
char buf[2000];
|
char buf[2000];
|
||||||
#else
|
|
||||||
char buf[8192];
|
|
||||||
#endif
|
|
||||||
struct ael_extension *exten;
|
struct ael_extension *exten;
|
||||||
struct ael_extension *exten_list = 0;
|
struct ael_extension *exten_list = 0;
|
||||||
|
|
||||||
@@ -4431,13 +4427,9 @@ int ast_compile_ael2(struct ast_context **local_contexts, struct ast_hashtab *lo
|
|||||||
case PV_GLOBALS:
|
case PV_GLOBALS:
|
||||||
/* just VARDEC elements */
|
/* just VARDEC elements */
|
||||||
for (p2=p->u1.list; p2; p2=p2->next) {
|
for (p2=p->u1.list; p2; p2=p2->next) {
|
||||||
#ifdef STANDALONE
|
char buf2[2000];
|
||||||
snprintf(buf, sizeof(buf), "%s=%s", p2->u1.str, p2->u2.val);
|
snprintf(buf2,sizeof(buf2),"%s=%s", p2->u1.str, p2->u2.val);
|
||||||
pbx_builtin_setvar(NULL, buf);
|
pbx_builtin_setvar(NULL, buf2);
|
||||||
#else
|
|
||||||
pbx_substitute_variables_helper(NULL, p2->u2.val, buf, sizeof(buf) - 1);
|
|
||||||
pbx_builtin_setvar_helper(NULL, p2->u1.str, buf);
|
|
||||||
#endif
|
|
||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
default:
|
default:
|
||||||
|
Reference in New Issue
Block a user