[asterisk-dev] SIP reinvite back to asterisk during async_goto

Tony Mountifield tony at softins.clara.co.uk
Thu Sep 18 11:59:16 CDT 2008


In article <5caa9b870809180837t794ee553h31b9e6b6be6fa832 at mail.gmail.com>,
Steve Davies <davies147 at gmail.com> wrote:
> 
> I am trying to put together an app to do essentially the same as the
> Manager "Action: Redirect" operation, so that 2 channels in a bridged
> call can be bounced off into the dialplan to do their own thing.
> 
> It is ALMOST working. The code is not complicated after-all, it runs
> ast_async_goto(...) on the 2 halves of the bridge once they've been
> identified. If I set canreinvite=no, or if the call is a SIP<->ZAP
> call, it works 100%.
> 
> The problem is if I have a reinvited SIP<->SIP call, then chan_sip/rtp
> never seems to reinvite the call back to Asterisk, so the audio paths
> which are subsequently set-up are all over the place. "show channel
> ..." shows that the channel has been "un-bridged", but the rtp code
> never seems to be called :( I also tried to send an AST_CONTROL_HOLD
> to the channel before doing the async_goto, in the hope that this
> would cause asterisk to grab the call before I do the goto, but it
> seems to make no difference - Probably because I do not release the
> channel lock between sending the HOLD, and doing the async_goto.
> 
> Any suggestions - I am running a Frankenstein version of asterisk, so
> it is possible this has already been discovered and fixed in a future
> version.

My first question would be: does Manager "Action: Redirect" do it
properly on a reinvited SIP<->SIP call?

If so, I guess you just need to compare your logic with its logic
step by step.

If not, it would be a more fundamental problem in Asterisk.

Apologies if I'm just stating the obvious.

Cheers
Tony

-- 
Tony Mountifield
Work: tony at softins.co.uk - http://www.softins.co.uk
Play: tony at mountifield.org - http://tony.mountifield.org



More information about the asterisk-dev mailing list