<div dir="ltr">lunch time here, gracias khalil.</div><div class="gmail_extra"><br><div class="gmail_quote">On Tue, Jan 24, 2017 at 1:02 PM, Khalil Khamlichi <span dir="ltr"><<a href="mailto:khamlichi.khalil@gmail.com" target="_blank">khamlichi.khalil@gmail.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr"><div class="gmail_extra"><font color="#000000" face="monospace">sorry :</font></div><div class="gmail_extra"><font color="#000000" face="monospace"><br></font></div><div class="gmail_extra"><span style="font-family:monospace"><font color="#000000">        <span style="font-weight:bold"># record routing</span>
<br>        record_route()<span style="font-weight:bold">;</span>
<br>
<br>        <span style="font-weight:bold"># create dialog with timeout</span>
</font><br>        if ( !create_dialog("B") ) {
<br>                send_reply("<wbr>500","Internal Server Error")<span style="font-weight:bold;color:rgb(84,255,255)">;</span><span style="color:rgb(0,0,0)">
</span><br>                exit<span style="font-weight:bold;color:rgb(84,255,255)">;</span><span style="color:rgb(0,0,0)">
</span><br>        }<br>
<br></span></div><span class=""><div class="gmail_extra"><span style="color:rgb(0,0,0);font-family:monospace;font-size:10.4px">        </span><span style="color:rgb(0,0,0);font-family:monospace;font-size:10.4px;font-weight:bold"># apply transformations from dialplan table</span><span style="color:rgb(0,0,0);font-family:monospace;font-size:10.4px"> </span><br style="color:rgb(0,0,0);font-family:monospace;font-size:10.4px"><span style="color:rgb(0,0,0);font-family:monospace;font-size:10.4px">       dp_translate("0","$rU/$</span><span style="color:rgb(0,0,0);font-family:monospace;font-size:10.4px"><wbr>rU")</span><span style="color:rgb(0,0,0);font-family:monospace;font-size:10.4px;font-weight:bold">;</span><span style="color:rgb(0,0,0);font-family:monospace;font-size:10.4px"> </span><br style="color:rgb(0,0,0);font-family:monospace;font-size:10.4px"><br style="color:rgb(0,0,0);font-family:monospace;font-size:10.4px"><span style="color:rgb(0,0,0);font-family:monospace;font-size:10.4px">       </span><span style="color:rgb(0,0,0);font-family:monospace;font-size:10.4px;font-weight:bold"># route calls based on prefix</span><span style="color:rgb(0,0,0);font-family:monospace;font-size:10.4px"> </span><br style="color:rgb(0,0,0);font-family:monospace;font-size:10.4px"><span style="color:rgb(0,0,0);font-family:monospace;font-size:10.4px">       if ( !do_routing("1","W",,"$var(</span><span style="color:rgb(0,0,0);font-family:monospace;font-size:10.4px">rul<wbr>e_attrs)","$var(gw_attrs)") ) { </span><br style="color:rgb(0,0,0);font-family:monospace;font-size:10.4px"><span style="color:rgb(0,0,0);font-family:monospace;font-size:10.4px">               send_reply("</span><span style="color:rgb(0,0,0);font-family:monospace;font-size:10.4px">404<wbr>","No Route found")</span><span style="color:rgb(0,0,0);font-family:monospace;font-size:10.4px;font-weight:bold">;</span><span style="color:rgb(0,0,0);font-family:monospace;font-size:10.4px"> </span><br style="color:rgb(0,0,0);font-family:monospace;font-size:10.4px"><span style="color:rgb(0,0,0);font-family:monospace;font-size:10.4px">               exit</span><span style="color:rgb(0,0,0);font-family:monospace;font-size:10.4px;font-weight:bold">;</span><span style="color:rgb(0,0,0);font-family:monospace;font-size:10.4px"> </span><br style="color:rgb(0,0,0);font-family:monospace;font-size:10.4px"><span style="color:rgb(0,0,0);font-family:monospace;font-size:10.4px">       } </span><br style="color:rgb(0,0,0);font-family:monospace;font-size:10.4px"><br style="color:rgb(0,0,0);font-family:monospace;font-size:10.4px"><span style="color:rgb(0,0,0);font-family:monospace;font-size:10.4px">       $acc_extra(gwid)=</span><span style="color:rgb(0,0,0);font-family:monospace;font-size:10.4px;font-weight:bold">$avp(g<wbr>w_id)</span><span style="color:rgb(0,0,0);font-family:monospace;font-size:10.4px;font-weight:bold">;</span><span style="color:rgb(0,0,0);font-family:monospace;font-size:10.4px"> </span><br style="color:rgb(0,0,0);font-family:monospace;font-size:10.4px"><br style="color:rgb(0,0,0);font-family:monospace;font-size:10.4px"><span style="color:rgb(0,0,0);font-family:monospace;font-size:10.4px">       t_on_failure("GW_</span><span style="color:rgb(0,0,0);font-family:monospace;font-size:10.4px">FAILOV<wbr>ER")</span><span style="color:rgb(0,0,0);font-family:monospace;font-size:10.4px;font-weight:bold">;</span><span style="color:rgb(0,0,0);font-family:monospace;font-size:10.4px"> </span><br style="color:rgb(0,0,0);font-family:monospace;font-size:10.4px"><br style="color:rgb(0,0,0);font-family:monospace;font-size:10.4px"><span style="color:rgb(0,0,0);font-family:monospace;font-size:10.4px">       do_accounting("db|log",</span><span style="color:rgb(0,0,0);font-family:monospace;font-size:10.4px"><wbr>"cdr|missed",)</span><span style="color:rgb(0,0,0);font-family:monospace;font-size:10.4px;font-weight:bold">;</span><span style="color:rgb(0,0,0);font-family:monospace;font-size:10.4px"> </span><br style="color:rgb(0,0,0);font-family:monospace;font-size:10.4px"><span style="color:rgb(0,0,0);font-family:monospace;font-size:10.4px;font-weight:bold">#NAT </span><span style="color:rgb(0,0,0);font-family:monospace;font-size:10.4px"> </span><br style="color:rgb(0,0,0);font-family:monospace;font-size:10.4px"><span style="color:rgb(0,0,0);font-family:monospace;font-size:10.4px">       if (isbflagset(NAT)) setflag(NAT)</span><span style="color:rgb(0,0,0);font-family:monospace;font-size:10.4px;font-weight:bold">;</span><span style="color:rgb(0,0,0);font-family:monospace;font-size:10.4px"> </span><br style="color:rgb(0,0,0);font-family:monospace;font-size:10.4px"><span style="color:rgb(0,0,0);font-family:monospace;font-size:10.4px;font-weight:bold">#NAT</span><span style="color:rgb(0,0,0);font-family:monospace;font-size:10.4px"> </span><br style="color:rgb(0,0,0);font-family:monospace;font-size:10.4px"><span style="color:rgb(0,0,0);font-family:monospace;font-size:10.4px;font-weight:bold">#TOPOHIDE</span><span style="color:rgb(0,0,0);font-family:monospace;font-size:10.4px"> </span><br style="color:rgb(0,0,0);font-family:monospace;font-size:10.4px"><span style="color:rgb(0,0,0);font-family:monospace;font-size:10.4px">        to</span><span style="color:rgb(0,0,0);font-family:monospace;font-size:10.4px;font-weight:bold">opology_hiding("UC");</span><span style="color:rgb(0,0,0);font-family:monospace;font-size:10.4px"> </span><br style="color:rgb(0,0,0);font-family:monospace;font-size:10.4px"><span style="color:rgb(0,0,0);font-family:monospace;font-size:10.4px;font-weight:bold">#TOPOHIDE</span><span style="color:rgb(0,0,0);font-family:monospace;font-size:10.4px"> </span><br style="color:rgb(0,0,0);font-family:monospace;font-size:10.4px"><span style="color:rgb(0,0,0);font-family:monospace;font-size:10.4px">       route(RELAY)</span><span style="color:rgb(0,0,0);font-family:monospace;font-size:10.4px;font-weight:bold">;</span><span style="color:rgb(0,0,0);font-family:monospace;font-size:10.4px"> </span><br style="color:rgb(0,0,0);font-family:monospace;font-size:10.4px"><br style="color:rgb(0,0,0);font-family:monospace;font-size:10.4px"><span style="color:rgb(0,0,0);font-family:monospace;font-size:10.4px">}</span><br></div></span></div>
</blockquote></div><br></div>