[sr-dev] git:master:0350885c: xhttp: more debug messages for sending the response

Daniel-Constantin Mierla miconda at gmail.com
Thu Mar 16 11:00:04 CET 2017


Module: kamailio
Branch: master
Commit: 0350885c076fa691de6106eb821ec5890572cee6
URL: https://github.com/kamailio/kamailio/commit/0350885c076fa691de6106eb821ec5890572cee6

Author: Daniel-Constantin Mierla <miconda at gmail.com>
Committer: Daniel-Constantin Mierla <miconda at gmail.com>
Date: 2017-03-16T10:53:51+01:00

xhttp: more debug messages for sending the response

---

Modified: src/modules/xhttp/xhttp_mod.c

---

Diff:  https://github.com/kamailio/kamailio/commit/0350885c076fa691de6106eb821ec5890572cee6.diff
Patch: https://github.com/kamailio/kamailio/commit/0350885c076fa691de6106eb821ec5890572cee6.patch

---

diff --git a/src/modules/xhttp/xhttp_mod.c b/src/modules/xhttp/xhttp_mod.c
index ca8ab32..2443de1 100644
--- a/src/modules/xhttp/xhttp_mod.c
+++ b/src/modules/xhttp/xhttp_mod.c
@@ -399,6 +399,7 @@ static int xhttp_send_reply(sip_msg_t *msg, int code, str *reason,
 			return -1;
 		}
 		pkg_free(tbuf.s);
+		LM_DBG("response with content-type: %.*s\n", ctype->len, ctype->s);
 	}
 
 	if(body!=NULL && body->len>0)
@@ -408,7 +409,9 @@ static int xhttp_send_reply(sip_msg_t *msg, int code, str *reason,
 			LM_ERR("Error while adding reply lump\n");
 			return -1;
 		}
+		LM_DBG("response with body: %.*s\n", body->len, body->s);
 	}
+	LM_DBG("sending out response: %d %.*s\n", code, reason->len, reason->s);
 	if (slb.freply(msg, code, reason) < 0)
 	{
 		LM_ERR("Error while sending reply\n");




More information about the sr-dev mailing list