answer call if header present

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

 



OK. Looking at *simple_pjsua.c* I see it auto-answer calls, but it does
always, and I need to check if a header is present before answering.

>From what I see on *pjsip-apps/src/samples/simpleua.c
*
it uses a callback:
*/* Notification on incoming messages */
static pj_bool_t logging_on_rx_msg(pjsip_rx_data *rdata) { ...*

That gets called on incoming SIP messages and it access a char buffer with
the headers.
I think I can get the info I need from there, but...

* This is the way to check headers on the higher level pjsua?
* The headers are somewhere parsed or I'll have to call the parsing
functions myself?

There seams to be a higher level way... I just don't want to do some dumb
re-parsing or something like that.

Thanks already,
Gabriel

2012/5/29 Fredrik Gustafsson <fug at svep.se>

> Look at pjsua_simple_client?****
>
> ** **
>
> *Fr?n:* pjsip-bounces at lists.pjsip.org [mailto:
> pjsip-bounces at lists.pjsip.org] *F?r *Gabriel Ortiz Lour
> *Skickat:* den 28 maj 2012 22:46
> *Till:* pjsip list
> *?mne:* [pjsip] answer call if header present****
>
> ** **
>
> Hi,
>
>   I'm starting a project with pjsip, build a very simple softphone.
>
>   I'd like to check the SIP headers of an incoming call, and if some
> special header are present, auto-answer it.
>
>   Could anyone give me some pointers on doing this?
>
> Thanks,
> Gabriel****
>
> _______________________________________________
> 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/b828ad38/attachment-0001.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