Module: kamailio
Branch: 5.0
Commit: 7d783adc7de603972966f50106471c06a6be2fac
URL:
https://github.com/kamailio/kamailio/commit/7d783adc7de603972966f50106471c0…
Author: Daniel-Constantin Mierla <miconda(a)gmail.com>
Committer: Daniel-Constantin Mierla <miconda(a)gmail.com>
Date: 2018-02-11T08:10:49+01:00
tmx: allocate space to store ending 0 for branch value
- reported by Alfred Farrugia and Sandro Gauci
(cherry picked from commit e1d8008a09d9390ebaf698abe8909e10dfec4097)
---
Modified: src/modules/tmx/tmx_pretran.c
---
Diff:
https://github.com/kamailio/kamailio/commit/7d783adc7de603972966f50106471c0…
Patch:
https://github.com/kamailio/kamailio/commit/7d783adc7de603972966f50106471c0…
---
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;