i think i found the bug that causes incorrect setting of dp_translate
attrs pvar value.
current code in dp_update function has this:
no_change = (dest->type == PVT_NONE) || (!repl->s) || (!repl->len);
if (no_change)
goto set_attr_pvar;
memset(&val, 0, siz
Juha Heinanen writes:
> my next guess is that this has something to do with amd64 architecture
> of the host. perhaps the sizes of ints/pointers/etc are not what the
> code somewhere expects?
i added check on length of int and pointer:
LM_INFO("got <%.*s>\n", res.rs.len, res.rs.s);
Daniel-Constantin Mierla writes:
> > 0(11244) ERROR: [sr_module.c:572]: ERROR: load_module: could not
> > open module : libkmi.so.1: cannot
> > open shared object file: No such file or directory
> >
> > when the file definitely exists:
> >
> > /usr/lib/sip-proxy/modules# ls -ls dialplan.so
> >
On 8/31/12 9:20 PM, Juha Heinanen wrote:
other weird thing is that when i tried to add more debug output to
dialplan module and compiled dialplan module separately on another host
(the same one where the debian package installed on this test host has
been built) and then copied it to the host (v
other weird thing is that when i tried to add more debug output to
dialplan module and compiled dialplan module separately on another host
(the same one where the debian package installed on this test host has
been built) and then copied it to the host (virtual machine) where these
tests are done,
> Aug 31 21:57:21 wheezy2 /usr/sbin/sip-proxy[9733]: INFO: Translating
> <+35892345670> based on dpid 4
> Aug 31 21:57:21 wheezy2 /usr/sbin/sip-proxy[9733]: INFO: Found attrs
> <598400320>
the result in attrs is pretty much random. sometimes i get the right
result and sometimes not. it does n
Daniel-Constantin Mierla writes:
> Can you set $var(plan) to a static string value before dp_translate()
> just to see if the value is updated in the function?
i now have:
xlog("L_INFO", "Translating <$var(calling_number)> based on dpid 4\n");
$var(plan) = "something";
if (dp_transl
I checked the commit log and there was no change in the module. Failure
to set the attrs variable is printing a error message, so looks like the
variable is set.
Can you set $var(plan) to a static string value before dp_translate()
just to see if the value is updated in the function?
Cheers,
Daniel-Constantin Mierla writes:
> What version are you using? Is it happening to get the right value
> from time to time?
this is with a few days old trunk:
version: sip-proxy 3.4.0-dev3 (x86_64/linux)
i have seen it sometimes to set attrs pvar correctly, but most times
not.
> If you set hig
Hello,
What version are you using? Is it happening to get the right value from time to
time?
If you set higher debug mode, is it printing the message that a rule was
matched?
Cheers,
Daniel
--
Daniel-Constantin Mierla
http://www.asipto.com
On 31 Aug 2012, at 18:15, Juha Heinanen wrote:
>
i have this piece of config code:
modparam("dialplan", "attrs_pvar", "$var(plan)")
...
xlog("L_INFO", "Translating <$var(calling_number)> based on dpid 4\n");
if (dp_translate("4", "$var(calling_number)")) {
xlog("L_INFO", "Found attrs <$var(plan)>\n");
...
dpid 4 has thr
11 matches
Mail list logo