Browse code

core: skip running event_route[core:pre-routing] for internal routed messages

Daniel-Constantin Mierla authored on 27/11/2020 12:25:50
Showing 1 changed files
... ...
@@ -235,6 +235,11 @@ int ksr_evrt_pre_routing(sip_msg_t *msg)
235 235
 	str evname = str_init("core:pre-routing");
236 236
 	recv_flags_t brflags;
237 237
 
238
+	if(msg->rcv.rflags & RECV_F_INTERNAL) {
239
+		DBG("skip internal routed message\n");
240
+		return 0;
241
+	}
242
+
238 243
 	if(kemi_pre_routing_callback.len>0) {
239 244
 		keng = sr_kemi_eng_get();
240 245
 		if(keng == NULL) {