answer call if header present

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi,

The  pjsip_msg_find_hdr_by_name may also help.
http://www.pjsip.org/docs/latest/pjsip/docs/html/group__PJSIP__MSG__MSG.htm#gaefbe5ae8b4f2a23e4d45adf57b7f3b7e

If searching the Call-Info (answer-after param); the Call-Info header is 
a type already known by pjsip 
(http://www.pjsip.org/docs/latest/pjsip/docs/html/group__PJSIP__MSG__HDR.htm#gae3f0331d450d7514919fcbbb2d844d67)
You may need to parse by hand content of the hvalue to find your param 
however.



On 29/05/2012 18:30, Matt DiMeo wrote:
> The pjsua on_incoming_call callback is passed a pjsip_rx_data*. 
> rdata->msg_info.msg is a pjsip_msg*,
> and you can loop through the headers with a loop like this:
>
>     pjsip_hdr *hdr ;
>     for (hdr = m->hdr.next ; hdr != &m->hdr ; hdr = hdr->next) {
>     }
>
>
>
> _______________________________________________
> Visit our blog: http://blog.pjsip.org
>
> pjsip mailing list
> pjsip at lists.pjsip.org
> http://lists.pjsip.org/mailman/listinfo/pjsip_lists.pjsip.org


-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.pjsip.org/pipermail/pjsip_lists.pjsip.org/attachments/20120529/65b361a1/attachment.html>


[Index of Archives]     [Asterisk Users]     [Asterisk App Development]     [Linux ARM Kernel]     [Linux ARM]     [Linux Omap]     [Fedora ARM]     [IETF Annouce]     [Security]     [Bugtraq]     [Linux]     [Linux OMAP]     [Linux MIPS]     [Linux API]
  Powered by Linux