- t_continue() - do not print error and return error code. - change func to log INFO so errors are not printed twice (once by tm and once by func call) You can view, comment on, or merge this pull request online at:
https://github.com/kamailio/kamailio/pull/2212
-- Commit Summary --
* tm: t_continue - do not print error and return error code
-- File Changes --
M src/modules/tm/t_suspend.c (2)
-- Patch Links --
https://github.com/kamailio/kamailio/pull/2212.patch https://github.com/kamailio/kamailio/pull/2212.diff
Hi, thanks for the pull request. Just briefly looked to the code, is t_continue not just a small wrapper around the t_continue_helper function? Where is the ERROR reported the second time?
`tm_continue()` is an API endpoint inside `tm` so other modules such as `tmx` call it.
if you look at `t_continue()` in `tmx` module, it checks return code and prints it's own log message: ` if(_tmx_tmb.t_continue(tindex, tlabel, act)<0)`
i think the API func should only print an error on critical failures. `t_lookup_ident_filter()` check is quiet graceful and should not alarm the system with an error message since it's very possible & often likely a transaction has completed when it's called.
Ah, I did misunderstood you here. But IMHO to report an INFO when the API call returns an error, is probably not the expectation of a caller. In the end this could be also used from other modules. I would suggest a WARN, similar to the condition when the transaction is not suspended below.
@eschmidbauer pushed 1 commit.
848a58234909b65b9f86ec32e494b243f75b4d08 tm: t_continue - do not print error and return error code
agreed. updated PR to use WARN level
Merged #2212 into master.
Thanks, merged