[sr-dev] git:master:d453bdd3: tcpops: more debug messages when executing event route

Daniel-Constantin Mierla miconda at gmail.com
Tue Sep 4 11:53:39 CEST 2018


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

Author: Daniel-Constantin Mierla <miconda at gmail.com>
Committer: Daniel-Constantin Mierla <miconda at gmail.com>
Date: 2018-09-04T11:52:58+02:00

tcpops: more debug messages when executing event route

---

Modified: src/modules/tcpops/tcpops.c

---

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

---

diff --git a/src/modules/tcpops/tcpops.c b/src/modules/tcpops/tcpops.c
index 8e5605c514..6815bf4897 100644
--- a/src/modules/tcpops/tcpops.c
+++ b/src/modules/tcpops/tcpops.c
@@ -204,6 +204,7 @@ static void tcpops_tcp_closed_run_route(tcp_closed_event_info_t *tev)
 	sip_msg_t *fmsg;
 
 	rt = tcp_closed_routes[tev->reason];
+	LM_DBG("event reason id: %d rt: %d\n", tev->reason, rt);
 	if (rt == -1) return;
 
 	if (faked_msg_init() < 0)
@@ -229,11 +230,13 @@ int tcpops_handle_tcp_closed(sr_event_param_t *evp)
 		LM_WARN("received bad TCP closed event\n");
 		return -1;
 	}
+	LM_DBG("received TCP closed event\n");
 
 	/* run event route if tcp_closed_event == 1 or if the
 	 * F_CONN_CLOSE_EV flag is explicitly set */
-	if (tcp_closed_event == 1 || (tev->con->flags & F_CONN_CLOSE_EV))
+	if (tcp_closed_event == 1 || (tev->con->flags & F_CONN_CLOSE_EV)) {
 		tcpops_tcp_closed_run_route(tev);
+	}
 
 	return 0;
 }




More information about the sr-dev mailing list