Module: sip-router Branch: master Commit: e82121b95c8418c81072a2d09bd74b3abfe49d27 URL: http://git.sip-router.org/cgi-bin/gitweb.cgi/sip-router/?a=commit;h=e82121b9...
Author: Jason Penton jason.penton@gmail.com Committer: Jason Penton jason.penton@gmail.com Date: Mon Feb 24 11:03:17 2014 +0200
modules/ims_usrloc_scscf: incorret assignment that causes incorrect shm free on pkg_malloc'd memory
---
modules/ims_usrloc_scscf/usrloc_db.c | 6 ++---- 1 files changed, 2 insertions(+), 4 deletions(-)
diff --git a/modules/ims_usrloc_scscf/usrloc_db.c b/modules/ims_usrloc_scscf/usrloc_db.c index 91a3061..4fad64e 100644 --- a/modules/ims_usrloc_scscf/usrloc_db.c +++ b/modules/ims_usrloc_scscf/usrloc_db.c @@ -614,10 +614,8 @@ int preload_udomain(db1_con_t* _c, udomain_t* _d) {
if (!VAL_NULL(vals + 7)) { blob = VAL_BLOB(vals + 7); - - bin_alloc(&x, VAL_BLOB(vals + 7).len); - memcpy(x.s, VAL_BLOB(vals + 7).s, VAL_BLOB(vals + 7).len); - x.s = blob.s; + bin_alloc(&x, blob.len); + memcpy(x.s, blob.s, blob.len); x.len = blob.len; x.max = 0; subscription = bin_decode_ims_subscription(&x);