[sr-dev] git:master: modules_k/siptrace Fixed crash when using HEP v2

Anca Vamanu anca.vamanu at 1and1.ro
Mon Oct 15 17:30:37 CEST 2012


Module: sip-router
Branch: master
Commit: 5d9d4d017d79d4e9269bbeb019460b3c8d8695d0
URL:    http://git.sip-router.org/cgi-bin/gitweb.cgi/sip-router/?a=commit;h=5d9d4d017d79d4e9269bbeb019460b3c8d8695d0

Author: Dragos Dinu <dragos.dinu at 1and1.ro>
Committer: Anca Vamanu <anca.vamanu at 1and1.ro>
Date:   Mon Oct 15 18:29:48 2012 +0300

modules_k/siptrace Fixed crash when using HEP v2

---

 modules_k/siptrace/siptrace.c |    3 +++
 1 files changed, 3 insertions(+), 0 deletions(-)

diff --git a/modules_k/siptrace/siptrace.c b/modules_k/siptrace/siptrace.c
index ea2e818..06111ab 100644
--- a/modules_k/siptrace/siptrace.c
+++ b/modules_k/siptrace/siptrace.c
@@ -1608,6 +1608,9 @@ static int trace_send_hep_duplicate(str *body, str *from, str *to)
 	}
 
 	hdr.hp_l +=len;
+	if (hep_version == 2){
+		len += sizeof(struct hep_timehdr);
+	}
 	len += sizeof(struct hep_hdr) + body->len;
 	buffer = (void *)pkg_malloc(len+1);
 	if (buffer==0){




More information about the sr-dev mailing list