manager: Fix appending variables.

The if statement here is always false after the for
loop finishes, so variables are never appended.
This removes that to properly append to the end
of the variable list.

ASTERISK-30351 #close
Reported by: Sebastian Gutierrez

Change-Id: I1b7f8b85a8918f6a814cb933a479d4278cf16199
18.17
Naveen Albert 3 years ago committed by Friendly Automation
parent db6e9c4e50
commit 9ede683f4e

@ -6279,11 +6279,9 @@ static int action_originate(struct mansession *s, const struct message *m)
vars = ast_variables_dup(s->session->chanvars);
if (old) {
for (v = vars; v->next; v = v->next );
if (v->next) {
v->next = old; /* Append originate variables at end of list */
}
}
}
/* For originate async - we can bridge in early media stage */
bridge_early = ast_true(early_media);

Loading…
Cancel
Save