[Spce-user] I'm stuck on routing MESSAGE (SIP SIMPLE) - [SOLVED]
Skyler
skchopperguy at gmail.com
Mon Jul 4 17:51:01 EDT 2011
Hi, Thank you very much for pointing me in the right direction Carsten. This
helped me learn what I was doing wrong and my issue is now resolved.
S.
-----Original Message-----
From: Carsten Bock [mailto:carsten at ng-voice.com]
Hi,
please look at the examples in the DokuWiki of Kamailio:
http://sip-router.org/wiki/cookbooks/core-cookbook/devel#switch
You should add a "break;" as in the example of the DokuWiki:
switch($retcode)
{
case -1:
log("process INVITE requests here\n");
break;
case 1:
log("process REGISTER requests here\n");
break;
case 2:
case 3:
log("process SUBSCRIBE and NOTIFY requests here\n");
break;
default:
log("process other requests here\n");
}
Carsten
2011/7/4 Skyler <skchopperguy at gmail.com>:
> Hi all,
>
>
>
> Trying to route MESSAGE by user location, my various attempts are failing
> miserably. At best I am getting WARNING: tm [t_lookup.c:1543]: WARNING:
> script writer didn't release transaction.
>
>
>
> How should I be writing this so as to route MESSAGEs to by location
> correctly in proxy.cfg.tt2? Any help is greatly appreciated.
>
>
>
>
>
> if(is_method("MESSAGE"))
>
> {
>
> if (!lookup("location")) {
>
> switch ($rc) {
>
> case -1:
>
> case -3:
>
> t_newtran();
>
> t_reply("404", "Not Found");
>
> exit;
>
> case -2:
>
> sl_send_reply("405", "Method Not Allowed");
>
> exit;
>
> }
>
> }
>
> }
>
>
>
>
>
> TIA,
>
> S.
More information about the Spce-user
mailing list