Module: kamailio
Branch: master
Commit: 1501e20b65f63c64a89b84196dc925cef79b7c76
URL:
https://github.com/kamailio/kamailio/commit/1501e20b65f63c64a89b84196dc925c…
Author: Daniel-Constantin Mierla <miconda(a)gmail.com>
Committer: Daniel-Constantin Mierla <miconda(a)gmail.com>
Date: 2018-09-11T20:31:07+02:00
jsonrpcs: print flags in error message when rpc reply is not initialized
---
Modified: src/modules/jsonrpcs/jsonrpcs_mod.c
---
Diff:
https://github.com/kamailio/kamailio/commit/1501e20b65f63c64a89b84196dc925c…
Patch:
https://github.com/kamailio/kamailio/commit/1501e20b65f63c64a89b84196dc925c…
---
diff --git a/src/modules/jsonrpcs/jsonrpcs_mod.c b/src/modules/jsonrpcs/jsonrpcs_mod.c
index 11857fe11e..5c558c60c4 100644
--- a/src/modules/jsonrpcs/jsonrpcs_mod.c
+++ b/src/modules/jsonrpcs/jsonrpcs_mod.c
@@ -775,7 +775,8 @@ static int jsonrpc_struct_add(srjson_t *jnode, char* fmt, ...)
ctx = &_jsonrpc_ctx;
if(ctx->jrpl==NULL) {
- LM_ERR("reply object not initialized in rpl context\n");
+ LM_ERR("reply object not initialized in rpl context - flags 0x%x\n",
+ ctx->flags);
return -1;
}
@@ -845,7 +846,8 @@ static int jsonrpc_array_add(srjson_t *jnode, char* fmt, ...)
ctx = &_jsonrpc_ctx;
if(ctx->jrpl==NULL) {
- LM_ERR("reply object not initialized in rpl context\n");
+ LM_ERR("reply object not initialized in rpl context - flags 0x%x\n",
+ ctx->flags);
return -1;
}
@@ -905,7 +907,8 @@ static int jsonrpc_struct_printf(srjson_t *jnode, char* mname, char*
fmt, ...)
ctx = &_jsonrpc_ctx;
if(ctx->jrpl==NULL) {
- LM_ERR("reply object not initialized in rpl context\n");
+ LM_ERR("reply object not initialized in rpl context - flags 0x%x\n",
+ ctx->flags);
return -1;
}