[Users] route on reply reason in failure_route

Daniel-Constantin Mierla daniel at voice-system.ro
Sun Jan 15 13:07:54 CET 2006


In the failure_route is processed the original INVITE. You cannot have 
access to the reply. What you can do is to set a onreply_route for the 
INVITE and in this route to set some avps to reply code and reason. 
Since the failure_route is executed after the onreply_route you can 
check them in failure_route.

Cheers,
Daniel


On 01/15/06 12:50, Walter Schober wrote:
> Can anyone please give me a hint how to access the reply reason in 
> failure_route - or is it really not possible to trigger some event on 
> the response _reason_.
>  0(704) SIP Reply  (status):
>  0(704)  version: <SIP/2.0>
>  0(704)  status:  <404>
>  0(704)  reason:  <CLIR Inactive>   <----- I want this!
> There is a pseudo variable for that, but no function can search the 
> replied reason!
> Is it really true, that you can use the reply status only 
> (t_check_status("404"))?
>  
> Using avpops the pseude variables $rr and $rs are <null> at that 
> moment. Do I miss something?
> I'm doing that:
> failure_route[3]
> {
>         if (t_check_status("404") ) {
>                 avp_printf("$reason", "The reply: $rr, $rs");
> log("\n----------------------------------------\n");
> avp_print();
> log("\n----------------------------------------\n");
>         }
> }
> resulting in:
>  0(740) DEBUG:avpops:print_avp: p=0xb6177838, flags=2
>  0(740) DEBUG:                  id=<32>
>  0(740) DEBUG:                  val_str=<The reply: <null>, <null>>
>
> Any hints welcome.
> /Walter
> ------------------------------------------------------------------------
>
> _______________________________________________
> Users mailing list
> Users at openser.org
> http://openser.org/cgi-bin/mailman/listinfo/users
>   




More information about the sr-users mailing list