[asterisk-dev] [Code Review] get_rpid function also didnt work right like the get_pai function

Mark Michelson reviewboard at asterisk.org
Thu Jan 19 13:50:17 CST 2012


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


It has come to my attention that there is a function in reqresp_parser.h called parse_name_andor_addr().

You can replace most of the content of get_pai() and get_rpid() with a single call to this function to get all the information out of it. The only problem is that for RPID, it won't parse the header parameters we need. You would still have to parse that out of the "remainder" or "residue" that parse_name_andor_addr() returns. I apologize for not recommending this function when you made your get_pai() review, but I only just now found about its existence.

- Mark


On Jan. 19, 2012, 9:45 a.m., schmidts wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviewboard.asterisk.org/r/1677/
> -----------------------------------------------------------
> 
> (Updated Jan. 19, 2012, 9:45 a.m.)
> 
> 
> Review request for Asterisk Developers.
> 
> 
> Summary
> -------
> 
> like the get_pai function the get_rpid function also didnt work well. By changing it to use the reqresp functions it works better.
> 
> i also changed some var names for better understanding,
> 
> the part about finding the privacy and screen params is very ugly but i dont have find a good way to solve this cause there isnt allready a reqresp parser for this.
> 
> 
> Diffs
> -----
> 
>   team/schmidts/unleash-the-beast/channels/chan_sip.c 350974 
> 
> Diff: https://reviewboard.asterisk.org/r/1677/diff
> 
> 
> Testing
> -------
> 
> tested with different RPID header values and privacy and screen settings.
> 
> 
> Thanks,
> 
> schmidts
> 
>

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.digium.com/pipermail/asterisk-dev/attachments/20120119/865ab47a/attachment-0001.htm>


More information about the asterisk-dev mailing list