Module: sip-router
Branch: master
Commit: bae7fcb9be9a4cf88693e6c4180e3c1e6f4b6c1d
URL:
http://git.sip-router.org/cgi-bin/gitweb.cgi/sip-router/?a=commit;h=bae7fcb…
Author: Jason Penton <jason.penton(a)smilecoms.com>
Committer: Jason Penton <jason.penton(a)smilecoms.com>
Date: Thu Oct 10 15:36:59 2013 +0200
modules/ims_charging: fixed bug not initialise AVP string value for success CCA
---
modules/ims_charging/ims_ro.c | 2 ++
modules/ims_charging/mod.h | 1 +
2 files changed, 3 insertions(+), 0 deletions(-)
diff --git a/modules/ims_charging/ims_ro.c b/modules/ims_charging/ims_ro.c
index 1907958..e1ff6de 100644
--- a/modules/ims_charging/ims_ro.c
+++ b/modules/ims_charging/ims_ro.c
@@ -1150,6 +1150,8 @@ static int create_cca_return_code(int result) {
avp_name.s.len = RO_AVP_CCA_RETURN_CODE_LENGTH;
avp_val.n = result;
+ avp_val.s.s = RO_RETURN_TRUE_STR; //assume true
+ avp_val.s.len = 1;
switch(result) {
case RO_RETURN_FALSE:
diff --git a/modules/ims_charging/mod.h b/modules/ims_charging/mod.h
index 95f5edf..9c0bc82 100644
--- a/modules/ims_charging/mod.h
+++ b/modules/ims_charging/mod.h
@@ -22,6 +22,7 @@
#define RO_RETURN_BREAK 0
/** Return true in the routing script */
#define RO_RETURN_TRUE 1
+#define RO_RETURN_TRUE_STR "1"
/** Return false in the routing script */
#define RO_RETURN_FALSE -1
#define RO_RETURN_FALSE_STR "-1"