[asterisk-dev] who will receive the SIP response first, SIP driver or the channel?

Joshua C. Colp jcolp at sangoma.com
Tue May 18 05:15:30 CDT 2021


pOn Tue, May 18, 2021 at 7:13 AM Mohit Dhiman <mohitdhiman736 at gmail.com>
wrote:

> Hi,
> Assuming I am using the chan_sip driver
> my question is for an outbound call If Asterisk receives any SIP Response
> (like 100 TRYING, 180 RINGING ...) which of the two will receive this frame
> data first will it be *handle_response_invite* of channels/chan_sip.c or
> will it be *ast_read* of the main/channel.c
>
> So far with my testing handle_response_invite is receiving the frame data
> first and then the ast_read, will this always be the case or is this a
> race thing where either of the functions can get the data first?
>

handle_response_invite would always get it first, as it is what understands
SIP responses and conveys it to the core.

-- 
Joshua C. Colp
Asterisk Technical Lead
Sangoma Technologies
Check us out at www.sangoma.com and www.asterisk.org
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.digium.com/pipermail/asterisk-dev/attachments/20210518/dc6b494c/attachment.html>


More information about the asterisk-dev mailing list