On May 30, 2009 at 09:16, Juha Heinanen <jh(a)tutpro.com> wrote:
this line
if (!t_relay("0x01")) {
gives error
0(6768) DEBUG: <core> [sr_module.c:515]: find_export_record: <t_relay> not
found
0(6768) DEBUG: <core> [sr_module.c:515]: find_export_record: <t_relay> not
found
0(6768) : <core> [cfg.y:2921]: parse error in config file, line 2884, column 21:
unknown command, missing loadmodule?
how can i achieve the same effect in sr, i.e., do not generate
provisional response.
modparam("tm", "auto_inv_100", 0) (globally)
or
t_set_auto_inv_100(0) (per transaction)
E.g.:
t_set_auto_inv_100(0);
t_relay();
also, how can the other flag values mapped?
0x02 - in sip-router the negative reply is generated at the end of the
script (and not internal inside t_relay()) and only if no reply from
script was generated. So one could always use t_reply() to change the
reply code, or t_release() to skip generating a reply.
I'm not sure if this is completely equivalent to the k 0x02.
0x04 - no equivalent, dns failover can be turned off only globally and
not per transaction.
in
case of failure, does t_relay always return -1 or are the other negative
values as well?
It can return other negative values, when called form a request route
(e.g.: E_BAD_ADDRESS, E_SEND, E_ADM_PROHIBITED, E_OUT_OF_MEM a.s.o,
see error.h for the negative values).
Andrei