[asterisk-dev] [Code Review] 2674: Abstract tech_pvt for chan_pjsip channels

opticron reviewboard at asterisk.org
Thu Jul 18 15:03:34 CDT 2013


-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviewboard.asterisk.org/r/2674/#review9169
-----------------------------------------------------------

Ship it!



/trunk/channels/chan_gulp.c
<https://reviewboard.asterisk.org/r/2674/#comment18095>

    How about ast_sip_channel_pvt?


- opticron


On July 15, 2013, noon, Joshua Colp wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviewboard.asterisk.org/r/2674/
> -----------------------------------------------------------
> 
> (Updated July 15, 2013, noon)
> 
> 
> Review request for Asterisk Developers and kmoore.
> 
> 
> Repository: Asterisk
> 
> 
> Description
> -------
> 
> chan_pjsip currently places its own structure within the tech_pvt of channels. This allows it to store additional information (like an array for quick media session lookups) but also means that given a channel it is not possible to get the session when you know it is a chan_pjsip channel. This is extremely useful for things like frame hooks and allows things to extend behavior and functionality easier.
> 
> The attached patch abstracts the tech_pvt for chan_pjsip channels a bit by having a defined structure which contains the implementation details and also the session itself. Since the structure is defined as part of res_sip_session modules can use it to get the session when need be.
> 
> I called the structure ast_sip_channel as I couldn't come up with anything else, but if you take offense to the name suggest a new one and it will be changed.
> 
> 
> Diffs
> -----
> 
>   /trunk/channels/chan_gulp.c 394388 
>   /trunk/include/asterisk/res_sip_session.h 394388 
>   /trunk/res/res_sip_session.c 394388 
>   /trunk/res/res_sip_session.exports.in 394388 
> 
> Diff: https://reviewboard.asterisk.org/r/2674/diff/
> 
> 
> Testing
> -------
> 
> Placed calls, confirmed sane.
> 
> 
> Thanks,
> 
> Joshua Colp
> 
>

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.digium.com/pipermail/asterisk-dev/attachments/20130718/870c0bf7/attachment.htm>


More information about the asterisk-dev mailing list