Module: kamailio Branch: 4.3 Commit: 938759112e00bdac837c09e407480872ae1aff35 URL: https://github.com/kamailio/kamailio/commit/938759112e00bdac837c09e407480872...
Author: Daniel-Constantin Mierla miconda@gmail.com Committer: Daniel-Constantin Mierla miconda@gmail.com Date: 2015-09-22T14:48:29+02:00
tsilo: print return error code by lookup_to_dset() in ts_append()
- helps figuring out why it failed
(cherry picked from commit 692c24ac7d6524cb2388534ee004d636c8b0c277)
---
Modified: modules/tsilo/ts_append.c
---
Diff: https://github.com/kamailio/kamailio/commit/938759112e00bdac837c09e407480872... Patch: https://github.com/kamailio/kamailio/commit/938759112e00bdac837c09e407480872...
---
diff --git a/modules/tsilo/ts_append.c b/modules/tsilo/ts_append.c index b2a9a9a..3714b84 100644 --- a/modules/tsilo/ts_append.c +++ b/modules/tsilo/ts_append.c @@ -69,6 +69,7 @@ int ts_append(struct sip_msg* msg, str *ruri, char *table) { int ts_append_to(struct sip_msg* msg, int tindex, int tlabel, char *table) { struct cell *t; struct sip_msg *orig_msg; + int ret;
if(_tmb.t_lookup_ident(&t, tindex, tlabel) < 0) { @@ -79,8 +80,9 @@ int ts_append_to(struct sip_msg* msg, int tindex, int tlabel, char *table) {
orig_msg = t->uas.request;
- if (_regapi.lookup_to_dset(orig_msg, table, NULL) != 1) { - LM_DBG("transaction %u:%u: error updating dset\n", tindex, tlabel); + ret = _regapi.lookup_to_dset(orig_msg, table, NULL); + if(ret != 1) { + LM_DBG("transaction %u:%u: error updating dset (%d)\n", tindex, tlabel, ret); return -1; }