Module: kamailio
Branch: 5.8
Commit: 26742e3b930cd5106de5d01fc9e5d04ac096cfe0
URL: 
https://github.com/kamailio/kamailio/commit/26742e3b930cd5106de5d01fc9e5d04ac096cfe0

Author: Daniel-Constantin Mierla <[email protected]>
Committer: Daniel-Constantin Mierla <[email protected]>
Date: 2026-03-05T18:03:13+01:00

core: adjust bufsize filed for event route message received

(cherry picked from commit c2639123993febc5b59f0127c2d97d79520a2928)
(cherry picked from commit 1ab4d31158030138c933a8d74b55ad2b2e78bd14)
(cherry picked from commit 4942b7dfe0b10c2e7d6a37033df35ab52e7a3267)

---

Modified: src/core/receive.c

---

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

---

diff --git a/src/core/receive.c b/src/core/receive.c
index 5c095196e2c..3e7e43aad08 100644
--- a/src/core/receive.c
+++ b/src/core/receive.c
@@ -195,7 +195,11 @@ int ksr_evrt_received(char *buf, unsigned int *len, 
receive_info_t *rcv_info,
        memset(&netinfo, 0, sizeof(sr_net_info_t));
        netinfo.data.s = buf;
        netinfo.data.len = *len;
-       netinfo.bufsize = BUF_SIZE;
+       if(evtype == KSR_EVRT_RECEIVED_MESSAGE) {
+               netinfo.bufsize = BUF_SIZE;
+       } else {
+               netinfo.bufsize = netinfo.data.len;
+       }
        netinfo.rcv = rcv_info;
        netinfo.evtype = evtype;
 

_______________________________________________
Kamailio - Development Mailing List -- [email protected]
To unsubscribe send an email to [email protected]
Important: keep the mailing list in the recipients, do not reply only to the 
sender!

Reply via email to