[sr-dev] git:master:6eedbab9: topos: use method_id to match KDMQ

Daniel-Constantin Mierla miconda at gmail.com
Thu Jun 7 09:26:47 CEST 2018


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

Author: Daniel-Constantin Mierla <miconda at gmail.com>
Committer: Daniel-Constantin Mierla <miconda at gmail.com>
Date: 2018-06-07T09:26:11+02:00

topos: use method_id to match KDMQ

---

Modified: src/modules/topos/topos_mod.c

---

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

---

diff --git a/src/modules/topos/topos_mod.c b/src/modules/topos/topos_mod.c
index 5d3e4aec9c..30090b6b16 100644
--- a/src/modules/topos/topos_mod.c
+++ b/src/modules/topos/topos_mod.c
@@ -400,12 +400,9 @@ int tps_msg_sent(sr_event_param_t *evp)
 		}
 
 		if(local==1 && dialog==0) {
-			if((get_cseq(&msg)->method_id) & (METHOD_OPTIONS|METHOD_NOTIFY)) {
-				/* skip local out-of-dialog requests (e.g., keepalive) */
-				goto done;
-			}
-			if(get_cseq(&msg)->method.len==4
-					&& strncmp(get_cseq(&msg)->method.s, "KDMQ", 4)==0) {
+			if((get_cseq(&msg)->method_id)
+						& (METHOD_OPTIONS|METHOD_NOTIFY|METHOD_KDMQ)) {
+				/* skip local out-of-dialog requests (e.g., keepalive, dmq) */
 				goto done;
 			}
 		}




More information about the sr-dev mailing list