expand vars in hold music variable

This commit is contained in:
Anthony Minessale 2012-07-26 13:17:39 -05:00
parent 93f96addc3
commit 696fb9c28b
1 changed files with 10 additions and 0 deletions

View File

@ -717,6 +717,16 @@ SWITCH_DECLARE(const char *) switch_channel_get_hold_music(switch_channel_t *cha
var = switch_channel_get_variable(channel, SWITCH_HOLD_MUSIC_VARIABLE); var = switch_channel_get_variable(channel, SWITCH_HOLD_MUSIC_VARIABLE);
} }
if (!zstr(var)) {
char *expanded = switch_channel_expand_variables(channel, var);
if (expanded != var) {
var = switch_core_session_strdup(channel->session, expanded);
free(expanded);
}
}
return var; return var;
} }