[Freeswitch-users] Possible problem in adding channel variables to the bridge

Jon Bruel jbr at consiglia.dk
Thu Sep 25 01:39:48 PDT 2008


Thanks Anthony. I have been confused because of the semantics:
execute_on_anwer implies that the code pointed at is re-executed.
Anyhow, including the application execute_extension in the
ONANSWER-code, helps but not every time: In 20-30% of all the instances,
the variable is passed on to the b-leg part of the ONANSWER. In other
cases the variable is still undefined.

When the b-leg of the ONANSWER runs before the a-leg part, it is
undefined, and vice versa. The code executed by execute_extension is:

<?xml version="1.0" encoding="utf-8"?>
<include>
  <context name="onanswer">
      <extension name="Call_Answered">
            <condition field="destination_number"
expression="^ONANSWER$">
            </condition>
            <condition field="${leg}" expression="^a$">
                  <action application="info"/>
                  <!-- We are in the b-leg-->
                  <anti-action application="set"
data="On_Answer_Is_It_Then_Passed=${NEWVARIABLE}"/>
                  <anti-action application="info"/>
            </condition>
      </extension>
  </context>
</include>

Jon

-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.freeswitch.org/pipermail/freeswitch-users/attachments/20080925/d86434a2/attachment-0002.html 


More information about the FreeSWITCH-users mailing list