[Asterisk-Dev] Per-call codec preference

Peter Svensson psvasterisk at psv.nu
Thu Jan 13 00:36:33 MST 2005


On Thu, 13 Jan 2005, Michael Giagnocavo wrote:

> Thanks for that pointer! 
> 
> The problem I've run into is that in iax2_call(), I have no way of accessing
> the channelvars that are set, since Dial does not copy them over. Of course,
> I could be missing something quite basic, as this is the first patch I've
> worked on for Asterisk.
> 
> I made a horrible hack by editing app_dial to copy the variable
> ("CODEC_OVERRIDE") (I'm listening for better names, perhaps
> PREFERRED_CODEC?), from chan to tmp->chan. That does the trick, but it's
> hackish.
> 
> So how can I get the original channel to grab the channelvars from
> iax2_call()?

Variables with "_" and "__" prepended to their names are inherited 
according to some rules. See the section on ALERT_INFO in 
  http://www.voip-info.org/wiki-Asterisk+SIP+channels

Peter





More information about the asterisk-dev mailing list