[sr-dev] git:5.0:d5f89eb4: tm: more info in some log messages

Daniel-Constantin Mierla miconda at gmail.com
Wed Sep 6 09:15:36 CEST 2017


Module: kamailio
Branch: 5.0
Commit: d5f89eb46c6d463d162dab0af1a7b56af513549c
URL: https://github.com/kamailio/kamailio/commit/d5f89eb46c6d463d162dab0af1a7b56af513549c

Author: Daniel-Constantin Mierla <miconda at gmail.com>
Committer: Daniel-Constantin Mierla <miconda at gmail.com>
Date: 2017-09-06T09:15:14+02:00

tm: more info in some log messages

(cherry picked from commit 8599f6fca16367a3e2a0dd4a638c667459482cd5)

---

Modified: src/modules/tm/t_lookup.c

---

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

---

diff --git a/src/modules/tm/t_lookup.c b/src/modules/tm/t_lookup.c
index 265633ca69..474ad63cbe 100644
--- a/src/modules/tm/t_lookup.c
+++ b/src/modules/tm/t_lookup.c
@@ -930,7 +930,7 @@ int t_reply_matching( struct sip_msg *p_msg , int *p_branch )
 		*p_branch =(int) branch_id;
 		REF_UNSAFE( T );
 		UNLOCK_HASH(hash_index);
-		LM_DBG("reply matched (T=%p)!\n",T);
+		LM_DBG("reply (%p) matched an active transaction (T=%p)!\n", p_msg, T);
 		if(likely(!(p_msg->msg_flags&FL_TM_RPL_MATCHED))) {
 			/* if this is a 200 for INVITE, we will wish to store to-tags to be
 			 * able to distinguish retransmissions later and not to call
@@ -997,8 +997,8 @@ int t_check_msg( struct sip_msg* p_msg , int *param_branch )
 
 	ret=0;
 	/* is T still up-to-date ? */
-	LM_DBG("msg id=%d global id=%d T start=%p\n",
-			p_msg->id,global_msg_id,T);
+	LM_DBG("msg (%p) id=%d global id=%d T start=%p\n",
+			p_msg,p_msg->id,global_msg_id,T);
 	if ( p_msg->id != global_msg_id || T==T_UNDEFINED )
 	{
 		global_msg_id = p_msg->id;
@@ -1063,17 +1063,17 @@ int t_check_msg( struct sip_msg* p_msg , int *param_branch )
 		if ( T && T!=T_UNDEFINED && T->flags & (T_IN_AGONY)) {
 			LM_WARN("transaction %p scheduled for deletion "
 					"and called from t_check_msg (flags=%x) (but it might be ok)"
-					"\n", T, T->flags);
+					" (msg %p)\n", T, T->flags, p_msg);
 		}
 #endif
-		LM_DBG("msg id=%d global id=%d T end=%p\n",
-				p_msg->id,global_msg_id,T);
+		LM_DBG("msg (%p) id=%d global id=%d T end=%p\n",
+				p_msg,p_msg->id,global_msg_id,T);
 	} else { /*  ( p_msg->id == global_msg_id && T!=T_UNDEFINED ) */
 		if (T){
-			LM_DBG("T already found!\n");
+			LM_DBG("T (%p) already found for msg (%p)!\n", T, p_msg);
 			ret=1;
 		}else{
-			LM_DBG("T previously sought and not found\n");
+			LM_DBG("T previously sought and not found for msg (%p)\n", p_msg);
 			ret=-1;
 		}
 		if (likely(param_branch))




More information about the sr-dev mailing list