[OpenSIPS-Users] how to cancel an INVITE before the callee receive it?
merlin.li at tsingch.com
merlin.li at tsingch.com
Thu Mar 5 11:16:42 CET 2015
Hi Chircu,
I got an idea, and tested it, but the result confuse me.
In the CANCEL processing block, i use set_dlg_flag("1") to set a dialog flag,
if (is_method("CANCEL")) # in the route block
{
if (t_check_trans()){
if(!is_dlg_flag_set("1")){
set_dlg_flag("1");
t_relay();
exit;
}
}
}
and in the while loop:
while( !lookup("location","m") ){
if(is_dlg_flag_set("1")){
t_reply("404","cancel the request!");
exit;
}
.....
}
Sometimes , it works well, but sometimes, the CANCEL process is not executed until the loop finished.
What i said is i got two result, and i don't know why.
result 1:
when opensips received the CANCEL request , the dialog flag is set, then break the while loop.
result 2:
Caller issue a CANCEL request, but opensips didn't entering the CANCEL process until the while loop is finished.
merlin.li at tsingch.com
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.opensips.org/pipermail/users/attachments/20150305/92e8790f/attachment.htm>
More information about the Users
mailing list