Module: kamailio
Branch: master
Commit: 692c24ac7d6524cb2388534ee004d636c8b0c277
URL:
https://github.com/kamailio/kamailio/commit/692c24ac7d6524cb2388534ee004d63…
Author: Daniel-Constantin Mierla <miconda(a)gmail.com>
Committer: Daniel-Constantin Mierla <miconda(a)gmail.com>
Date: 2015-09-21T18:20:24+02:00
tsilo: print return error code by lookup_to_dset() in ts_append()
- helps figuring out why it failed
---
Modified: modules/tsilo/ts_append.c
---
Diff:
https://github.com/kamailio/kamailio/commit/692c24ac7d6524cb2388534ee004d63…
Patch:
https://github.com/kamailio/kamailio/commit/692c24ac7d6524cb2388534ee004d63…
---
diff --git a/modules/tsilo/ts_append.c b/modules/tsilo/ts_append.c
index 0805cdd..1295f03 100644
--- a/modules/tsilo/ts_append.c
+++ b/modules/tsilo/ts_append.c
@@ -73,6 +73,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)
{
@@ -83,8 +84,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;
}