mirror of
https://github.com/asterisk/asterisk.git
synced 2025-09-05 12:16:00 +00:00
Merge "res_ael: Use Gosub in for loop expressions" into 13
This commit is contained in:
@@ -3536,18 +3536,14 @@ static int gen_prios(struct ael_extension *exten, char *label, pval *statement,
|
|||||||
strcpy(buf2, strp3);
|
strcpy(buf2, strp3);
|
||||||
strp3 = strchr(buf2,'(');
|
strp3 = strchr(buf2,'(');
|
||||||
if (strp3) {
|
if (strp3) {
|
||||||
*strp3 = '|';
|
*strp3 = ',';
|
||||||
}
|
|
||||||
while ((strp3=strchr(buf2,','))) {
|
|
||||||
*strp3 = '|';
|
|
||||||
}
|
}
|
||||||
strp3 = strrchr(buf2, ')');
|
strp3 = strrchr(buf2, ')');
|
||||||
if (strp3)
|
if (strp3)
|
||||||
*strp3 = 0; /* remove the closing paren */
|
*strp3 = 0; /* remove the closing paren */
|
||||||
|
|
||||||
for_init->appargs = strdup(buf2);
|
for_init->appargs = strdup(buf2);
|
||||||
free(for_init->app);
|
free(for_init->app);
|
||||||
for_init->app = strdup("Macro");
|
for_init->app = strdup("Gosub");
|
||||||
} else { /* must be a regular app call */
|
} else { /* must be a regular app call */
|
||||||
char *strp3;
|
char *strp3;
|
||||||
strcpy(buf2, strp2);
|
strcpy(buf2, strp2);
|
||||||
@@ -3594,7 +3590,7 @@ static int gen_prios(struct ael_extension *exten, char *label, pval *statement,
|
|||||||
|
|
||||||
for_inc->appargs = strdup(buf2);
|
for_inc->appargs = strdup(buf2);
|
||||||
|
|
||||||
for_inc->app = strdup("Macro");
|
for_inc->app = strdup("Gosub");
|
||||||
} else { /* must be a regular app call */
|
} else { /* must be a regular app call */
|
||||||
char *strp3;
|
char *strp3;
|
||||||
strcpy(buf2, strp2);
|
strcpy(buf2, strp2);
|
||||||
|
Reference in New Issue
Block a user