[SR-Users] weird dp_translate result

Juha Heinanen jh at tutpro.com
Fri Aug 31 18:15:13 CEST 2012


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 three entries:

109	4	10	1	^\+1	0		na
107	4	10	1	^\+358	0		fi
108	4	10	1	^\+46	0		se

thus in each entry attrs field has some two letter value.

when the above piece of code is executed, i get to syslog

Aug 31 19:06:51 wheezy2 /usr/sbin/sip-proxy[7162]: INFO: Translating <+35892345670> based on dpid 4
Aug 31 19:06:51 wheezy2 /usr/sbin/sip-proxy[7162]: INFO: Found attrs <0>

if i restart the proxy, attrs value may change to some other bogus
value.

any ideas?

-- juha





More information about the sr-users mailing list