Module: kamailio
Branch: master
Commit: e1d8008a09d9390ebaf698abe8909e10dfec4097
URL:
https://github.com/kamailio/kamailio/commit/e1d8008a09d9390ebaf698abe8909e1…
Author: Daniel-Constantin Mierla <miconda(a)gmail.com>
Committer: Daniel-Constantin Mierla <miconda(a)gmail.com>
Date: 2018-02-10T22:05:42+01:00
tmx: allocate space to store ending 0 for branch value
- reported by Alfred Farrugia and Sandro Gauci
---
Modified: src/modules/tmx/tmx_pretran.c
---
Diff:
https://github.com/kamailio/kamailio/commit/e1d8008a09d9390ebaf698abe8909e1…
Patch:
https://github.com/kamailio/kamailio/commit/e1d8008a09d9390ebaf698abe8909e1…
---
diff --git a/src/modules/tmx/tmx_pretran.c b/src/modules/tmx/tmx_pretran.c
index 494bdffe3e..67c4f7f4af 100644
--- a/src/modules/tmx/tmx_pretran.c
+++ b/src/modules/tmx/tmx_pretran.c
@@ -260,7 +260,7 @@ int tmx_check_pretran(sip_msg_t *msg)
if(likely(vbr!=NULL)) {
svbranch = vbr->value;
trim(&svbranch);
- dsize += svbranch.len;
+ dsize += svbranch.len + 1;
}
if(dsize<256) dsize = 256;